Esempio n. 1
0
        private void deviceTwinCallback(int update_state, IntPtr payload, int size, UIntPtr userContextCallback)
        {
            string strPayload = Marshal.PtrToStringAnsi(payload, size);
            DeviceTwinCallbackArgs deviceTwinCallbackArgs = new DeviceTwinCallbackArgs(update_state, strPayload, userContextCallback);

            OnDeviceTwinCallback(deviceTwinCallbackArgs);
        }
Esempio n. 2
0
        protected virtual void OnDeviceTwinCallback(DeviceTwinCallbackArgs e)
        {
            EventHandler <DeviceTwinCallbackArgs> handler = DeviceTwinCallback;

            if (handler != null)
            {
                handler(this, e);
            }
        }