Index: src/client/c/hu/varadiistvan/xplra/MultiBuffer.cc
===================================================================
--- src/client/c/hu/varadiistvan/xplra/MultiBuffer.cc	(revision 22)
+++ src/client/c/hu/varadiistvan/xplra/MultiBuffer.cc	(revision 26)
@@ -141,4 +141,11 @@
 //------------------------------------------------------------------------------
 
+void MultiBuffer::forgetRegistration() throw()
+{
+    registeredID = -1;
+}
+
+//------------------------------------------------------------------------------
+
 inline const MultiBuffer::DataRef* MultiBuffer::getLastDataRef() const throw()
 {
Index: src/client/c/hu/varadiistvan/xplra/MultiBuffer.h
===================================================================
--- src/client/c/hu/varadiistvan/xplra/MultiBuffer.h	(revision 22)
+++ src/client/c/hu/varadiistvan/xplra/MultiBuffer.h	(revision 26)
@@ -155,5 +155,4 @@
                 uint8_t unregisterCommand) throw();
 
-public:
     /**
      * Destroy the buffer. If it is registered, an attempt will be
@@ -162,4 +161,5 @@
     virtual ~MultiBuffer() throw(Exception);
 
+public:
     /**
      * Add an integer dataref.
@@ -477,4 +477,12 @@
 
     /**
+     * Forget the registration of this buffer. This is called from the
+     * destructor of the XPlane object, since that closes the
+     * connection anyway, so there is no need to unregister the
+     * multi-buffers.
+     */
+    void forgetRegistration() throw();
+
+    /**
      * Get the last dataref, or 0 if there are not datarefs yet.
      */
@@ -524,4 +532,6 @@
     getArray(size_t id, size_t offset) const
         throw(InvalidIDException, TypeMismatchException);
+
+    friend class XPlane;
 };
 
Index: src/client/c/hu/varadiistvan/xplra/MultiGetter.h
===================================================================
--- src/client/c/hu/varadiistvan/xplra/MultiGetter.h	(revision 22)
+++ src/client/c/hu/varadiistvan/xplra/MultiGetter.h	(revision 26)
@@ -44,5 +44,5 @@
 class MultiGetter : public MultiBuffer
 {
-public:
+private:
     /**
      * Construct the object for the given XPlane instance.
@@ -67,4 +67,6 @@
      */
     void read(const DataRef& dataRef) throw(Exception);
+
+    friend class XPlane;
 };
 
Index: src/client/c/hu/varadiistvan/xplra/MultiSetter.h
===================================================================
--- src/client/c/hu/varadiistvan/xplra/MultiSetter.h	(revision 22)
+++ src/client/c/hu/varadiistvan/xplra/MultiSetter.h	(revision 26)
@@ -44,5 +44,5 @@
 class MultiSetter : public MultiBuffer
 {
-public:
+private:
     /**
      * Construct the object for the given XPlane instance.
@@ -67,4 +67,6 @@
      */
     void write(const DataRef& dataRef) const throw(Exception);
+
+    friend class XPlane;
 };
 
Index: src/client/c/hu/varadiistvan/xplra/XPlane.cc
===================================================================
--- src/client/c/hu/varadiistvan/xplra/XPlane.cc	(revision 19)
+++ src/client/c/hu/varadiistvan/xplra/XPlane.cc	(revision 26)
@@ -31,4 +31,7 @@
 #include "XPlane.h"
 
+#include "MultiGetter.h"
+#include "MultiSetter.h"
+
 #include <hu/varadiistvan/scpl/io/LocalClientSocket.h>
 #include <hu/varadiistvan/scpl/io/DataStream.h>
@@ -41,4 +44,6 @@
 
 using hu::varadiistvan::xplra::XPlane;
+using hu::varadiistvan::xplra::MultiGetter;
+using hu::varadiistvan::xplra::MultiSetter;
 
 using hu::varadiistvan::scpl::io::LocalClientSocket;
@@ -104,4 +109,11 @@
 {
     disconnect();
+    for(multiBuffers_t::iterator i = multiBuffers.begin();
+        i!=multiBuffers.end(); ++i)
+    {
+        MultiBuffer* buffer = *i;
+        buffer->forgetRegistration();
+        delete buffer;
+    }
 }
 
@@ -138,4 +150,35 @@
     delete stream; stream = 0;
     delete socket; socket = 0;
+}
+
+//------------------------------------------------------------------------------
+
+MultiGetter& XPlane::createMultiGetter() throw()
+{
+    MultiGetter* getter = new MultiGetter(*this);
+    multiBuffers.insert(getter);
+    return *getter;
+}
+
+//------------------------------------------------------------------------------
+
+MultiSetter& XPlane::createMultiSetter() throw()
+{
+    MultiSetter* setter = new MultiSetter(*this);
+    multiBuffers.insert(setter);
+    return *setter;
+}
+
+//------------------------------------------------------------------------------
+
+bool XPlane::destroyMultiBuffer(MultiBuffer& buffer) throw(Exception)
+{
+    multiBuffers_t::iterator i = multiBuffers.find(&buffer);
+    if (i==multiBuffers.end()) return false;
+
+    multiBuffers.erase(i);
+    delete &buffer;
+
+    return true;
 }
 
Index: src/client/c/hu/varadiistvan/xplra/XPlane.h
===================================================================
--- src/client/c/hu/varadiistvan/xplra/XPlane.h	(revision 19)
+++ src/client/c/hu/varadiistvan/xplra/XPlane.h	(revision 26)
@@ -35,4 +35,6 @@
 #include <hu/varadiistvan/scpl/io/Waiter.h>
 
+#include <set>
+
 #include <inttypes.h>
 
@@ -49,4 +51,10 @@
 
 namespace hu { namespace varadiistvan { namespace xplra {
+
+//------------------------------------------------------------------------------
+
+class MultiBuffer;
+class MultiGetter;
+class MultiSetter;
 
 //------------------------------------------------------------------------------
@@ -61,4 +69,9 @@
 private:
     /**
+     * Type for the set of multi-dataref buffers.
+     */
+    typedef std::set<MultiBuffer*> multiBuffers_t;
+
+    /**
      * The waiter to use.
      */
@@ -74,4 +87,9 @@
      */
     scpl::io::DataStream* stream;
+
+    /**
+     * The buffers created by this object.
+     */
+    multiBuffers_t multiBuffers;
 
 public:
@@ -84,5 +102,6 @@
     /**
      * Destroy the object. If connected, the connection will be
-     * closed.
+     * closed. It destroys all existing buffers, so their references
+     * become invalid.
      */
     ~XPlane() throw();
@@ -102,4 +121,26 @@
      */
     void disconnect() throw();
+
+    /**
+     * Create a new getter of multiple datarefs and return a reference
+     * to it.
+     */
+    MultiGetter& createMultiGetter() throw();
+
+    /**
+     * Create a new setter of multiple datarefs and return a reference
+     * to it.
+     */
+    MultiSetter& createMultiSetter() throw();
+
+    /**
+     * Destroy the given getter or setter of multiple datarefs. As the
+     * buffer is unregistered, if it has been registered previously,
+     * and  unregistration may fail, this function might throw an
+     * exception.
+     *
+     * @return if the buffer was found and could be destroyed
+     */
+    bool destroyMultiBuffer(MultiBuffer& buffer) throw(Exception);
 
     /**
