コード例 #1
0
ファイル: ExampleCode.cs プロジェクト: StevenHouben/NooSphere
 static void activitySystem_DeviceAdded(object sender, DeviceEventArgs e)
 {
     Console.WriteLine("Device {0} received directly from activitysystem", e.Device.Name);
 }
コード例 #2
0
ファイル: ExampleCode.cs プロジェクト: StevenHouben/NooSphere
        static void activityClient_DeviceAdded(object sender, DeviceEventArgs e)
        {
            Console.WriteLine("Device {0} received from activityclient over http", e.Device.Name);

            Console.WriteLine("Associated user is {0}",e.Device.Owner.Name);
        }
コード例 #3
0
 protected virtual void OnDeviceChanged(DeviceEventArgs e)
 {
     var handler = DeviceChanged;
     if (handler != null) handler(this, e);
 }
コード例 #4
0
 void ActivityNode_DeviceAdded( object sender, DeviceEventArgs e )
 {
     devices.AddOrUpdate( e.Device.Id, e.Device, ( key, oldValue ) => e.Device );
 }
コード例 #5
0
 void ActivityNode_DeviceChanged( object sender, DeviceEventArgs e )
 {
     devices[ e.Device.Id ].UpdateAllProperties( e.Device );
 }
コード例 #6
0
 void ActivitySystem_DeviceAdded(object sender, DeviceEventArgs e)
 {
     Notifier.NotifyAll(NotificationType.DeviceAdded, e.Device);
 }