Esempio n. 1
0
 private void Add(Type messageType, HandleFunc func)
 {
     if (_services == null)
     {
         _services = new List <HandleService>();
     }
     _services.Add(new HandleService(_handlerService, messageType, func));
 }
        public TunnelSslMitm(ProxyStream stream, CancellationToken token, X509Certificate2 certificate, SslProtocols sslProtocols, HandleFunc handler)
            : base(stream, token)
        {
            this.m_sslProtocols = sslProtocols;
            this.m_certificate  = certificate;

            this.m_handler = handler;
        }
Esempio n. 3
0
 public void Add(Action.E_Type type, HandleFunc handleFunc)
 {
     handlers.Add(type, handleFunc);
 }
Esempio n. 4
0
 public ConfigItemTimed(ItemType type, string parameter, int delay, HandleFunc func)
     : base(type, parameter)
 {
     Timer = new Timer();
     _func = func;
     Timer.Elapsed += Handler;
     Timer.Interval = delay * 60000;
     Timer.Start();
 }
Esempio n. 5
0
 public DelegateRequestHandler(HandleFunc handle) => _handle = handle;
 public HandleService(Service handler, Type messageType, HandleFunc handleFunc)
 {
     Handler     = handler;
     MessageType = messageType;
     HandleFunc  = handleFunc;
 }
Esempio n. 7
0
 public HandlerPlain(ProxyStream stream, CancellationToken token, HandleFunc handler)
     : base(stream, token)
 {
     this.m_handler = handler;
 }