ber_first_element

Positions the state of a BerElement to its first element and returns the type of the first element.

Library:*ldapsdk.*
NDS Version:7.xx or higher
Platform:NLM, Windows (NT, 95, 98, 2000, XP, Vista 32-bit and 64-bit ), Linux (32-bit and 64-bit), Solaris, AIX, and HP-UX

Syntax

  #include <ldap.h> or <lber.h>
  
  ber_tag_t ber_first_element (
     BerElement  *ber,
     ber_len_t   *lenPtr,
     char       **opaquePtr);
  

Parameters

ber

(IN) Points to the first element in the constructed type.

lenPtr

(OUT) Is used for internal use only. Use this value in the subsequent call to the ber_next_element function.

opaquePtr

(OUT) Is used for internal use only.Use this value in the subsequent call to the ber_next_element function

Return Values

On success, returns a tag indicating the type of the first element. Returns LBER_DEFAULT if there are no elements.

Remarks

Use the ber_scanf function to obtain the value of the first element.

See Also

ber_scanf