public RegisterKeyNotificationCommand(string key, short updateCallbackid, short removeCallbackid,bool notifyOnItemExpiration)
        {
            base.name = "RegisterKeyNotificationCommand";
            base.key = key;

            _registerKeyNotifCommand = new Alachisoft.NCache.Common.Protobuf.RegisterKeyNotifCommand();
            _registerKeyNotifCommand.key = key;

            _registerKeyNotifCommand.removeCallbackId = removeCallbackid;
            _registerKeyNotifCommand.updateCallbackId = updateCallbackid;
            _registerKeyNotifCommand.notifyOnExpiration = notifyOnItemExpiration;

            _registerKeyNotifCommand.requestId = base.RequestId;
        }
        public RegisterKeyNotificationCommand(string key, short updateCallbackid, short removeCallbackid, bool notifyOnItemExpiration)
        {
            base.name = "RegisterKeyNotificationCommand";
            base.key  = key;

            _registerKeyNotifCommand     = new Alachisoft.NCache.Common.Protobuf.RegisterKeyNotifCommand();
            _registerKeyNotifCommand.key = key;

            _registerKeyNotifCommand.removeCallbackId   = removeCallbackid;
            _registerKeyNotifCommand.updateCallbackId   = updateCallbackid;
            _registerKeyNotifCommand.notifyOnExpiration = notifyOnItemExpiration;

            _registerKeyNotifCommand.requestId = base.RequestId;
        }
Ejemplo n.º 3
0
        //PROTOBUF
        private CommandInfo ParseCommand(Alachisoft.NCache.Common.Protobuf.Command command, ClientManager clientManager)
        {
            CommandInfo cmdInfo = new CommandInfo();

            cmdInfo.NotifyOnExpiration = true;

            Alachisoft.NCache.Common.Protobuf.RegisterKeyNotifCommand registerKeyNotifCommand = command.registerKeyNotifCommand;
            cmdInfo.Key = registerKeyNotifCommand.key;
            cmdInfo.RemoveCallbackId   = (short)registerKeyNotifCommand.removeCallbackId;
            cmdInfo.RequestId          = registerKeyNotifCommand.requestId.ToString();
            cmdInfo.UpdateCallbackId   = (short)registerKeyNotifCommand.updateCallbackId;
            cmdInfo.NotifyOnExpiration = registerKeyNotifCommand.notifyOnExpiration;

            cmdInfo.dataFilter = registerKeyNotifCommand.datafilter;

            return(cmdInfo);
        }