28 references to Forest
System.DirectoryServices (27)
System\DirectoryServices\ActiveDirectory\ActiveDirectorySchema.cs (4)
92if ((context.ContextType != DirectoryContextType.Forest) && 109if (context.ContextType == DirectoryContextType.Forest) 146if (context.ContextType == DirectoryContextType.Forest) 383return ActiveDirectorySchema.GetSchema(new DirectoryContext(DirectoryContextType.Forest));
System\DirectoryServices\ActiveDirectory\ActiveDirectorySite.cs (2)
193new DirectoryContext(DirectoryContextType.Forest); 215DirectoryContext currentContext = Utils.GetNewDirectoryContext(forestName, DirectoryContextType.Forest, null);
System\DirectoryServices\ActiveDirectory\DirectoryContext.cs (8)
109if (contextType != DirectoryContextType.Domain && contextType != DirectoryContextType.Forest) 140if (contextType != DirectoryContextType.Domain && contextType != DirectoryContextType.Forest) 189if ((contextType == DirectoryContextType.Domain) || ((contextType == DirectoryContextType.Forest) && (context.Name == null))) 246else if (contextType == DirectoryContextType.Forest) 382if (_contextType != DirectoryContextType.Forest) 387_contextIsValid = IsContextValid(this, DirectoryContextType.Forest); 504case DirectoryContextType.Forest: 511if ((_name == null) || ((_contextType == DirectoryContextType.Forest) && (isCurrentForest())))
System\DirectoryServices\ActiveDirectory\Domain.cs (2)
831DirectoryContext forestContext = Utils.GetNewDirectoryContext(forestName, DirectoryContextType.Forest, context); 1389DirectoryContext tmpContext = Utils.GetNewDirectoryContext(context.Name, DirectoryContextType.Forest, context);
System\DirectoryServices\ActiveDirectory\Forest.cs (5)
95if ((context.ContextType != DirectoryContextType.Forest) && 111if (context.ContextType == DirectoryContextType.Forest) 144if (context.ContextType == DirectoryContextType.Forest) 485DirectoryContext targetContext = Utils.GetNewDirectoryContext(targetForestName, DirectoryContextType.Forest, _context); 620public static Forest GetCurrentForest() => GetForest(new DirectoryContext(DirectoryContextType.Forest));
System\DirectoryServices\ActiveDirectory\GlobalCatalog.cs (6)
93if (context.ContextType != DirectoryContextType.Forest) 105if (context.ContextType != DirectoryContextType.Forest) 119if (context.ContextType != DirectoryContextType.Forest) 131if (context.ContextType != DirectoryContextType.Forest) 145if (context.ContextType != DirectoryContextType.Forest) 160if (context.ContextType != DirectoryContextType.Forest)
System.DirectoryServices.AccountManagement (1)
System\DirectoryServices\AccountManagement\AD\ADStoreCtx.cs (1)
1192Forest forest = Forest.GetForest(new DirectoryContext(DirectoryContextType.Forest, this.DnsForestName, this.credentials?.UserName, this.credentials?.Password));