Example #1
0
 public Service()
 {
     invokeManager = new InvokeManager(Execute);
     ioManager     = new IOManager(Process);
     foreach (var pair in handlerTypes)
     {
         var handler = Activator.CreateInstance(pair.Value, new object[] { this });
         handlers[pair.Key] = handler;
     }
     Add(methodManager.GetNames, "~");
 }
Example #2
0
        public Service()
        {
            invokeManager = new InvokeManager(Execute);
            ioManager     = new IOManager(Process);
            foreach (var pair in handlerTypes)
            {
#if !NET35_CF
                var handler = Activator.CreateInstance(pair.Value, new object[] { this });
#else
                var handler = pair.Value.GetConstructor(new Type[] { typeof(Service) }).Invoke(new object[] { this });
#endif
                handlers[pair.Key] = handler;
            }
            Add(methodManager.GetNames, "~");
        }