AdamInstanceCollection.IndexOf(AdamInstance) Método

Definição

Retorna o índice da primeira ocorrência do objeto AdamInstance especificado nesta coleção.Returns the index of the first occurrence of the specified AdamInstance object in this collection.

public:
 int IndexOf(System::DirectoryServices::ActiveDirectory::AdamInstance ^ adamInstance);
public int IndexOf (System.DirectoryServices.ActiveDirectory.AdamInstance adamInstance);
member this.IndexOf : System.DirectoryServices.ActiveDirectory.AdamInstance -> int
Public Function IndexOf (adamInstance As AdamInstance) As Integer

Parâmetros

adamInstance
AdamInstance

O objeto AdamInstance a ser pesquisado nesta coleção.The AdamInstance object to search for in this collection.

Retornos

Int32

O índice de base zero do primeiro objeto de correspondência.The zero-based index of the first matching object. Retornará -1 se nenhum membro dessa coleção for idêntico ao objeto AdamInstance.Returns -1 if no member of this collection is identical to the AdamInstance object.

Exceções

Uma chamada ao serviço de diretório subjacente resultou em um erro.A call to the underlying directory service resulted in an error.

adamInstance é null.adamInstance is null.

Aplica-se a

Confira também