00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _BUFFFEREDPROPERTY_HH_
00025 #define _BUFFFEREDPROPERTY_HH_
00026
00027 #include <typeinfo>
00028 #include <set>
00029
00030 class BufferedLocalProperty;
00031
00032 #include <vos/corelibs/vos/vos.hh>
00033 #include "property.hh"
00034
00035
00036
00037
00038
00039
00040
00041 class PROPERTY_API BufferedLocalProperty : public virtual LocalProperty
00042 {
00043 protected:
00044 static set<BufferedLocalProperty*> allblps;
00045 bool changed;
00046 int changestart;
00047 int changelen;
00048 public:
00049 BufferedLocalProperty(MetaObject* superobject);
00050 BufferedLocalProperty(MetaObject* superobject, const string& d, const string& dt = "?");
00051 virtual ~BufferedLocalProperty();
00052 static MetaObject* new_BufferedLocalProperty(MetaObject* superobject, const string& type);
00053 static void registerExtenders();
00054
00055
00056
00057
00058 static void flushAll();
00059
00060 virtual void write(int start, const string& newdata);
00061 virtual void replace(const string& newdata, const string& newtype = "?");
00062
00063
00064 virtual void flush();
00065 };
00066
00067
00068
00069 class PROPERTY_API BufferedRemoteProperty : public virtual RemoteProperty
00070 {
00071 protected:
00072 static set<BufferedRemoteProperty*> allbrps;
00073 bool changed;
00074 int changestart;
00075 int changelen;
00076 bool lastmsgsuccess;
00077 string lastnonce;
00078
00079 public:
00080 BufferedRemoteProperty(MetaObject* superobject);
00081 ~BufferedRemoteProperty();
00082 static MetaObject* new_BufferedRemoteProperty(MetaObject* superobject, const string& type);
00083 static void registerExtenders();
00084 static void flushAll();
00085
00086 virtual void write(int start, const string& newdata);
00087 virtual void replace(const string& newdata, const string& newtype = "?");
00088 virtual void flush();
00089 virtual void sendUpdateMessage(Message* m);
00090 };
00091
00092 #endif