コード例 #1
0
        public void DisplayDiscoveryEndpoint(NeighborhoodWatch nw)
        {
            var headerViewModel = _view.EndpointViewHeaderElement.DataContext as EndpointViewHeaderViewModel;

            if (headerViewModel != null)
            {
                headerViewModel.SystemName = nw.Computer;
                SystemName = nw.Computer;

                headerViewModel.ImageHeader           = "../../Images/logo_noagent.png";
                headerViewModel.ActivedButtonIndex    = 1;
                headerViewModel.ColorCodeMessageColor = CommonConstants.GREEN_OFFLINE_COLOR;
                headerViewModel.TextStatusVisible     = true;
                headerViewModel.ColorCodeMessage      = "";
                OSName              = nw.OperatingSystem;
                UserName            = "";
                SystemManufacturer  = nw.Vendor;
                SystemType          = "";
                SystemModel         = "";
                LastSync            = nw.LastDetected;
                PowerState          = "Offline";
                Processor           = "";
                TotalPhysicalMemory = 0;
                ComputerType        = "";
                Domain              = nw.Domain;
                IPv4           = nw.IPv4;
                IPv6           = nw.IPv6;
                MACAddress     = nw.MAC;
                HDDCapacity    = "0";
                ProductVersion = "1.0.0.0";
            }
        }
コード例 #2
0
 private void AddOrRemoveConfirmed(NeighborhoodWatch cust)
 {
     using (var sc = new POCServiceClient("NetTcpBinding_IPOCService"))
     {
         var data = JsonConvert.SerializeObject(cust);
         sc.SaveNeighborhoodWatchConfirmed(EncryptionHelper.EncryptString(data, KeyEncryption));
     }
 }