When using
var context = new PrincipalContext(ContextType.Domain);
It will connect to the domain of the current context, usually the domain the user who ran the application is logged into, or will throw an exception if the current context is a local user not connected to a domain.
When using
var context = new PrincipalContext(ContextType.Domain, domainName, domainContainer);
The domain property allows you to connect to a domain other than the one of the current context, assuming the current context has permissions or you supply valid credentials. So for example in an environment where there is multiple domains in a forest or domain trusts in place, you can specify another domain to run queries against instead of the one the user is a member of.
The container properties limits all queries using that DomainContext
to the specified container.