PrincipalContext Classe

Definição

Encapsula o servidor ou domínio em relação ao qual todas as operações são realizadas, o contêiner usado como base para essas operações e as credenciais usadas para executar as operações.Encapsulates the server or domain against which all operations are performed, the container that is used as the base of those operations, and the credentials used to perform the operations.

public ref class PrincipalContext : IDisposable
public class PrincipalContext : IDisposable
[System.Security.SecurityCritical(System.Security.SecurityCriticalScope.Everything)]
public class PrincipalContext : IDisposable
type PrincipalContext = class
    interface IDisposable
[<System.Security.SecurityCritical(System.Security.SecurityCriticalScope.Everything)>]
type PrincipalContext = class
    interface IDisposable
Public Class PrincipalContext
Implements IDisposable
Herança
PrincipalContext
Atributos
Implementações

Comentários

Para operações de pesquisa, o contexto principal define a base de pesquisa e, para operações de inserção, o contexto define o contêiner no qual o objeto é inserido.For search operations, the principal context defines the search base, and for insert operations the context defines the container into which the object is inserted.

Construtores

PrincipalContext(ContextType)

Inicializa uma nova instância da classe PrincipalContext com o tipo de contexto especificado.Initializes a new instance of the PrincipalContext class with the specified context type.

PrincipalContext(ContextType, String)

Inicializa uma nova instância da classe PrincipalContext com o tipo e nome de contexto especificados.Initializes a new instance of the PrincipalContext class with the specified context type and name.

PrincipalContext(ContextType, String, String)

Inicializa uma nova instância da classe PrincipalContext com o tipo de contexto, o nome e o contêiner especificados.Initializes a new instance of the PrincipalContext class with the specified context type, name, and container.

PrincipalContext(ContextType, String, String, ContextOptions)

Inicializa uma nova instância da classe PrincipalContext com o tipo de contexto, o nome, o contêiner e as opções de contexto especificados.Initializes a new instance of the PrincipalContext class with the specified context type, name, container, and context options.

PrincipalContext(ContextType, String, String, ContextOptions, String, String)

Inicializa uma nova instância da classe PrincipalContext com o tipo de contexto, o nome, o contêiner, as opções de contexto, o nome de usuário e a senha especificados.Initializes a new instance of the PrincipalContext class with the specified context type, name, container, context options, username, and password.

PrincipalContext(ContextType, String, String, String)

Inicializa uma nova instância da classe PrincipalContext com o tipo de contexto, o nome, o nome de usuário e a senha especificados.Initializes a new instance of the PrincipalContext class with the specified context type, name, username, and password.

PrincipalContext(ContextType, String, String, String, String)

Inicializa uma nova instância da classe PrincipalContext com o tipo de contexto, o nome, o contêiner, o nome de usuário e a senha especificados.Initializes a new instance of the PrincipalContext class with the specified context type, name, container, username, and password.

Propriedades

ConnectedServer

Obtém o nome do servidor ao qual o contexto da entidade de segurança está conectado.Gets the name of the server to which the principal context is connected.

Container

Obtém o valor especificado no parâmetro de contêiner no construtor.Gets the value specified in the container parameter in the constructor.

ContextType

Obtém o tipo de contexto que especifica o tipo de repositório para o contexto da entidade de segurança.Gets the context type that specifies the type of store for the principal context.

Name

Obtém o valor especificado como o parâmetro name no construtor.Gets the value specified as the name parameter in the constructor.

Options

Obtém as opções especificadas no parâmetro contextOptions do construtor.Gets the options specified in the contextOptions parameter of the constructor.

UserName

Obtém o valor especificado no parâmetro de nome de usuário no construtor.Gets the value specified in the username parameter in the constructor.

Métodos

Dispose()

Descarta a instância atual do objeto PrincipalContext.Disposes the current instance of the PrincipalContext object.

Equals(Object)

Determina se o objeto especificado é igual ao objeto atual.Determines whether the specified object is equal to the current object.

(Herdado de Object)
GetHashCode()

Serve como a função de hash padrão.Serves as the default hash function.

(Herdado de Object)
GetType()

Obtém o Type da instância atual.Gets the Type of the current instance.

(Herdado de Object)
MemberwiseClone()

Cria uma cópia superficial do Object atual.Creates a shallow copy of the current Object.

(Herdado de Object)
ToString()

Retorna uma cadeia de caracteres que representa o objeto atual.Returns a string that represents the current object.

(Herdado de Object)
ValidateCredentials(String, String)

Cria conexões com o servidor e retorna um valor booliano que especifica se o nome de usuário especificado e a senha são válidos.Creates the connections to the server and returns a Boolean value that specifies whether the specified username and password are valid.

ValidateCredentials(String, String, ContextOptions)

Cria as conexões com o servidor e retorna um valor booliano que especifica se o nome de usuário especificado e a senha são válidos.Creates the connections to the server and returns a Boolean value that specifies whether the specified user name and password are valid. Esse método executa a validação de credencial rápida do nome de usuário e senha.This method performs fast credential validation of the username and password.

Aplica-se a