예제 #1
0
        public Device()
        {
            m_nativeInstance = DeviceNative.Create();

            IntPtr controllerHandle = DeviceNative.GetController(m_nativeInstance);

            m_controller = new Controller(controllerHandle);
        }
예제 #2
0
        public void Dispose()
        {
            m_controller = null;

            if (m_nativeInstance != IntPtr.Zero)
            {
                DeviceNative.Destroy(m_nativeInstance);
                m_nativeInstance = IntPtr.Zero;
            }
        }
예제 #3
0
 public bool IsThisDevice(DeviceAddress address)
 {
     return(DeviceNative.IsThisDevice(m_nativeInstance, address.NativeInstance));
 }
예제 #4
0
 public void RemovePort(IntPtr portHandle)
 {
     DeviceNative.RemovePort(m_nativeInstance, portHandle);
 }
예제 #5
0
 public IntPtr AddPort(string hostname, UInt16 hostPort)
 {
     return(DeviceNative.AddPort(m_nativeInstance, hostname, hostPort));
 }
예제 #6
0
 public void Loop()
 {
     DeviceNative.Loop(m_nativeInstance);
 }