|
|||||
ldap.attribute
|
The ldap.attribute OMX component allows you to perform actions on the entry or attribute instance by using the OmniMark LDAP (OMLDAP) library functions.
Within your program, you can create as many instances of the ldap.attribute OMX component as you require by declaring global and local variables of type "ldap.attribute".
An LDAP attribute may contain either binary or text values. All functions that manipulate an LDAP attribute allow you to specify whether the attribute value is binary or text. Text values are the default. If it is binary, you must specify ldap.binary-type as the type.
Once you have declared your ldap.attribute OMX variables, you can display, add, delete, or change them with the functions in the OmniMark LDAP library. This example outputs the value of the "phonenumber" attribute in the first entry satisfying the search request.
import "omldap.xmd" prefixed by ldap. process local ldap.connection my-ldap local ldap.attribute my-entry variable set my-ldap to ldap.open 'www.stilo.com' ldap.search my-ldap base "o=stilo.com" where "(Department=rd)" into my-entry select "phonenumber" do when ldap.entry-exists my-entry output ldap.entry-name of my-entry || ": " || ldap.reader of my-entry{"phonenumber"} || "%n" done