Beispiel #1
0
            // Token: 0x06004FA1 RID: 20385 RVA: 0x0012602C File Offset: 0x0012422C
            public static ExchangeTopologyDiscovery CreateFrom(ExchangeTopologyDiscovery.Simple topology)
            {
                ArgumentValidator.ThrowIfNull("topology", topology);
                ExchangeTopologyDiscovery exchangeTopologyDiscovery = new ExchangeTopologyDiscovery(topology.DiscoveryStarted, topology.TopologyScope);

                exchangeTopologyDiscovery.localServerFqdn       = topology.LocalServerFqdn;
                exchangeTopologyDiscovery.sites                 = SimpleADObject.CreateList <ADSite>(topology.Sites, ExchangeTopologyDiscovery.Simple.aDSiteSchema, null);
                exchangeTopologyDiscovery.siteLinks             = SimpleADObject.CreateList <ADSiteLink>(topology.SiteLinks, ExchangeTopologyDiscovery.Simple.aDSiteLinkSchema, null);
                exchangeTopologyDiscovery.servers               = SimpleADObject.CreateList <MiniTopologyServer>(topology.Servers, ExchangeTopologyDiscovery.Simple.serverSchema, null);
                exchangeTopologyDiscovery.virtualDirectories    = SimpleADObject.CreateList <MiniVirtualDirectory>(topology.VirtualDirectories, ExchangeTopologyDiscovery.Simple.virtualDirectorySchema, null);
                exchangeTopologyDiscovery.emailTransports       = SimpleADObject.CreateList <MiniEmailTransport>(topology.EmailTransports, ExchangeTopologyDiscovery.Simple.emailTransportSchema, null);
                exchangeTopologyDiscovery.smtpReceiveConnectors = SimpleADObject.CreateList <MiniReceiveConnector>(topology.SmtpReceiveConnectors, ExchangeTopologyDiscovery.Simple.receiveConnectorSchema, null);
                List <ADServer> list = SimpleADObject.CreateList <ADServer>(topology.ADServers, ExchangeTopologyDiscovery.Simple.aDServerSchema, null);

                exchangeTopologyDiscovery.aDServers = new ReadOnlyCollection <ADServer>(list);
                return(exchangeTopologyDiscovery);
            }
Beispiel #2
0
 // Token: 0x06004FA2 RID: 20386 RVA: 0x0012610C File Offset: 0x0012430C
 public static ExchangeTopologyDiscovery.Simple Deserialize(byte[][] data)
 {
     ArgumentValidator.ThrowIfNull("data", data);
     if (data.Length != 3 || data[0] == null || data[1] == null || data[2] == null)
     {
         throw new ArgumentException("data");
     }
     ExchangeTopologyDiscovery.Simple simple = new ExchangeTopologyDiscovery.Simple();
     using (MemoryStream memoryStream = new MemoryStream(data[0]))
     {
         using (BinaryReader binaryReader = new BinaryReader(memoryStream))
         {
             simple.DiscoveryStarted = DateTime.FromBinary(binaryReader.ReadInt64());
             simple.TopologyScope    = (ExchangeTopologyScope)binaryReader.ReadInt32();
             simple.LocalServerFqdn  = binaryReader.ReadString();
             simple.Sites            = SimpleADObject.ReadList(binaryReader);
             simple.SiteLinks        = SimpleADObject.ReadList(binaryReader);
             simple.Servers          = SimpleADObject.ReadList(binaryReader);
         }
     }
     using (MemoryStream memoryStream2 = new MemoryStream(data[1]))
     {
         using (BinaryReader binaryReader2 = new BinaryReader(memoryStream2))
         {
             simple.VirtualDirectories    = SimpleADObject.ReadList(binaryReader2);
             simple.EmailTransports       = SimpleADObject.ReadList(binaryReader2);
             simple.SmtpReceiveConnectors = SimpleADObject.ReadList(binaryReader2);
         }
     }
     using (MemoryStream memoryStream3 = new MemoryStream(data[2]))
     {
         using (BinaryReader binaryReader3 = new BinaryReader(memoryStream3))
         {
             simple.ADServers = SimpleADObject.ReadList(binaryReader3);
         }
     }
     return(simple);
 }
Beispiel #3
0
 // Token: 0x06004FA5 RID: 20389 RVA: 0x001263E4 File Offset: 0x001245E4
 public bool Equals(ExchangeTopologyDiscovery.Simple right)
 {
     return(right != null && (this.TopologyScope == right.TopologyScope && this.LocalServerFqdn == right.LocalServerFqdn && SimpleADObject.ListEquals(this.Sites, right.Sites) && SimpleADObject.ListEquals(this.SiteLinks, right.SiteLinks) && SimpleADObject.ListEquals(this.Servers, right.Servers) && SimpleADObject.ListEquals(this.VirtualDirectories, right.VirtualDirectories) && SimpleADObject.ListEquals(this.EmailTransports, right.EmailTransports) && SimpleADObject.ListEquals(this.SmtpReceiveConnectors, right.SmtpReceiveConnectors)) && SimpleADObject.ListEquals(this.ADServers, right.ADServers));
 }