Example #1
0
        private void AddClientListener <CQK, CQV>(Event.ClientListener <CQK, CQV> cl, string[] filterFactoryParams, string[] converterFactoryParams, Action recoveryCallback)
        {
            VectorVectorChar vvcFilterParams = new VectorVectorChar();

            foreach (string s in filterFactoryParams)
            {
                vvcFilterParams.Add(toVectorChar(marshaller.ObjectToByteBuffer(s)));
            }

            VectorVectorChar vvcConverterParams = new VectorVectorChar();

            foreach (string s in converterFactoryParams)
            {
                vvcConverterParams.Add(toVectorChar(marshaller.ObjectToByteBuffer(s)));
            }
            InternalClientEventListenerCallback <CQK, CQV> cb = new InternalClientEventListenerCallback <CQK, CQV>(cl, marshaller);
            DotNetClientListener listener = cache.addClientListener(cb, toVectorChar(cl.filterFactoryName), toVectorChar(cl.converterFactoryName), cl.includeCurrentState, vvcFilterParams, vvcConverterParams, cl.useRawData, cl.interestFlag);

            cl.listenerId = toByteArray(listener.getUListenerId());
            addListener(cl.listenerId, listener);
        }
Example #2
0
 static void addListener(byte[] listenerId, DotNetClientListener tuple)
 {
     runnningListeners.Add(listenerId, tuple);
 }