Example #1
0
        public Api(string dllPath, CallBack callback)
            : base(dllPath)
        {
            _initialize   = GetHandler <InitializeHandler>("Initialize");
            _uninitialize = GetHandler <UninitializeHandler>("UnInitialize");
            _freeMemory   = GetHandler <FreeMemoryHandler>("FreeMemory");
            _setLogLevel  = GetHandler <SetLogLevelHandler>("SetLogLevel");
            _sendCommand  = GetHandler <SendCommandHandler>("SendCommand");
            _setCallback  = GetHandler <SetCallbackHandler>("SetCallback");
            //_setCallbackEx = GetHandler<SetCallbackExHandler>("SetCallbackEx");

            _callback = callback;

            SetCallback(_callback);

            // SetCallbackEx(OnCallBackEx, IntPtr.Zero);
        }
Example #2
0
		public Api(string dllPath, CallBack callback)
			: base(dllPath)
		{
			_initialize = GetHandler<InitializeHandler>("Initialize");
			_uninitialize = GetHandler<UninitializeHandler>("UnInitialize");
			_freeMemory = GetHandler<FreeMemoryHandler>("FreeMemory");
			_setLogLevel = GetHandler<SetLogLevelHandler>("SetLogLevel");
			_sendCommand = GetHandler<SendCommandHandler>("SendCommand");
			_setCallback = GetHandler<SetCallbackHandler>("SetCallback");
			//_setCallbackEx = GetHandler<SetCallbackExHandler>("SetCallbackEx");

			_callback = callback;
			
			SetCallback(_callback);
			
			// SetCallbackEx(OnCallBackEx, IntPtr.Zero);
		}