Example #1
0
        public void Deserialize(Runtime.Serialization.IO.CompactReader reader)
        {
            cacheIsRunning    = reader.ReadBoolean();
            cacheIsRegistered = reader.ReadBoolean();
            licenseIsExpired  = reader.ReadBoolean();

            name         = reader.ReadObject() as string;
            inproc       = reader.ReadBoolean();
            cacheType    = reader.ReadObject() as string;
            log          = reader.ReadObject() as Log;
            perfCounters = reader.ReadObject() as PerfCounters;

            indexes              = reader.ReadObject() as QueryIndex;
            backingSource        = reader.ReadObject() as BackingSource;
            notifications        = reader.ReadObject() as Notifications;
            cleanup              = reader.ReadObject() as Cleanup;
            storage              = reader.ReadObject() as Storage;
            evictionPolicy       = reader.ReadObject() as EvictionPolicy;
            expirationPolicy     = reader.ReadObject() as ExpirationPolicy;
            cluster              = reader.ReadObject() as Cluster;
            _replicationStrategy = reader.ReadObject() as ReplicationStrategy;

            autoBalancing            = reader.ReadObject() as AutoLoadBalancing;
            clientNodes              = reader.ReadObject() as ClientNodes;
            _sqlDependencyConfig     = reader.ReadObject() as SQLDependencyConfig;
            _taskConfiguration       = reader.ReadObject() as TaskConfiguration;
            deathDetection           = reader.ReadObject() as ClientDeathDetection;
            _runtimeContextValue     = reader.ReadObject() as string == "1" ? RtContextValue.JVCACHE : RtContextValue.NCACHE;
            _synchronizationStrategy = reader.ReadObject() as SynchronizationStrategy;

            string temp = reader.ReadObject() as String;

            _dataFormat = Common.Enum.DataFormat.Binary;
            clientActivityNotification = reader.ReadObject() as ClientActivityNotification;
        }
Example #2
0
        public void Deserialize(Runtime.Serialization.IO.CompactReader reader)
        {
            inproc                   = reader.ReadBoolean();
            lastModified             = reader.ReadObject() as String;
            cacheType                = reader.ReadObject() as String;
            log                      = reader.ReadObject() as Log;
            perfCounters             = reader.ReadObject() as Alachisoft.NCache.Config.Dom.PerfCounters;
            backingSource            = reader.ReadObject() as BackingSource;
            notifications            = reader.ReadObject() as Notifications;
            cleanup                  = reader.ReadObject() as Cleanup;
            storage                  = reader.ReadObject() as Alachisoft.NCache.Config.Dom.Storage;
            evictionPolicy           = reader.ReadObject() as EvictionPolicy;
            security                 = reader.ReadObject() as Alachisoft.NCache.Config.Dom.Security;
            autoBalancing            = reader.ReadObject() as AutoLoadBalancing;
            _synchronizationStrategy = reader.ReadObject() as SynchronizationStrategy;

            cacheTopology = reader.ReadObject() as CacheTopology;



            string temp = reader.ReadObject() as String;

            if (temp.ToLower().Equals("binary"))
            {
                _dataFormat = Common.Enum.DataFormat.Binary;
            }
            else if (temp.ToLower().Equals("object"))
            {
                _dataFormat = Common.Enum.DataFormat.Object;
            }
            deathDetection             = reader.ReadObject() as ClientDeathDetection;
            clientActivityNotification = reader.ReadObject() as ClientActivityNotification;
        }
Example #3
0
        public object Clone()
        {
            BackingSource store = new BackingSource();

            store.Readthru  = Readthru != null ? (Readthru)Readthru.Clone(): null;
            store.Writethru = Writethru != null ? (Writethru)Writethru.Clone(): null;
            return(store);
        }
Example #4
0
            private static BackingSource GetBackingSource(Hashtable settings)
            {
                BackingSource backingSource = new BackingSource();

                if (settings.ContainsKey("read-thru"))
                {
                    backingSource.Readthru = GetReadThru((Hashtable)settings["read-thru"]);
                }
                if (settings.ContainsKey("write-thru"))
                {
                    backingSource.Writethru = GetWriteThru((Hashtable)settings["write-thru"]);
                }
                return(backingSource);
            }
Example #5
0
        public void Deserialize(Runtime.Serialization.IO.CompactReader reader)
        {
            cacheIsRunning    = reader.ReadBoolean();
            cacheIsRegistered = reader.ReadBoolean();
            licenseIsExpired  = reader.ReadBoolean();
            name                     = reader.ReadObject() as string;
            inproc                   = reader.ReadBoolean();
            configID                 = reader.ReadString();
            configVersion            = reader.ReadDouble();
            lastModified             = reader.ReadObject() as string;
            cacheType                = reader.ReadObject() as string;
            log                      = reader.ReadObject() as Log;
            perfCounters             = reader.ReadObject() as PerfCounters;
            backingSource            = reader.ReadObject() as BackingSource;
            notifications            = reader.ReadObject() as Notifications;
            cleanup                  = reader.ReadObject() as Cleanup;
            storage                  = reader.ReadObject() as Storage;
            evictionPolicy           = reader.ReadObject() as EvictionPolicy;
            cluster                  = reader.ReadObject() as Cluster;
            _replicationStrategy     = reader.ReadObject() as ReplicationStrategy;
            security                 = reader.ReadObject() as Security;
            autoBalancing            = reader.ReadObject() as AutoLoadBalancing;
            clientNodes              = reader.ReadObject() as ClientNodes;
            _sqlDependencyConfig     = reader.ReadObject() as SQLDependencyConfig;
            deathDetection           = reader.ReadObject() as ClientDeathDetection;
            _runtimeContextValue     = reader.ReadObject() as string == "1" ? RtContextValue.JVCACHE : RtContextValue.NCACHE;
            _synchronizationStrategy = reader.ReadObject() as SynchronizationStrategy;
            string temp = reader.ReadObject() as String;

            if (temp.ToLower().Equals("binary"))
            {
                _dataFormat = Common.Enum.DataFormat.Binary;
            }
            else if (temp.ToLower().Equals("object"))
            {
                _dataFormat = Common.Enum.DataFormat.Object;
            }
            clientActivityNotification = reader.ReadObject() as ClientActivityNotification;
            depversion = (double)reader.ReadObject();
        }
        public void Deserialize(Runtime.Serialization.IO.CompactReader reader)
        {
            inproc                   = reader.ReadBoolean();
            cacheType                = reader.ReadObject() as String;
            log                      = reader.ReadObject() as Log;
            perfCounters             = reader.ReadObject() as Alachisoft.NCache.Config.Dom.PerfCounters;
            indexes                  = reader.ReadObject() as QueryIndex;
            backingSource            = reader.ReadObject() as BackingSource;
            notifications            = reader.ReadObject() as Notifications;
            cleanup                  = reader.ReadObject() as Cleanup;
            storage                  = reader.ReadObject() as Alachisoft.NCache.Config.Dom.Storage;
            evictionPolicy           = reader.ReadObject() as EvictionPolicy;
            expirationPolicy         = reader.ReadObject() as ExpirationPolicy;
            _sqlDependencyConfig     = reader.ReadObject() as SQLDependencyConfig;
            _synchronizationStrategy = reader.ReadObject() as SynchronizationStrategy;
            cacheTopology            = reader.ReadObject() as CacheTopology;
            _taskConfiguration       = reader.ReadObject() as TaskConfiguration;

            string temp = reader.ReadObject() as String;

            _dataFormat                = Common.Enum.DataFormat.Binary;
            deathDetection             = reader.ReadObject() as ClientDeathDetection;
            clientActivityNotification = reader.ReadObject() as ClientActivityNotification;
        }