Programmer Reference : LDAP : The LDAP Players : LdapEntry Operations
LdapEntry Operations
A successful search for a DN will return a single instance of LdapEntry in the LdapSearch. For instance, searching for
'cn=Aimee Rivest,ou=Payroll,dc=example,dc=com'
will return the LDAP entry for Aimee Rivest.
Some of the messages you can send to an LdapEntry are:
addValues: aCollection toAttribute: aString
Add values in aCollection to the attribute named aString. (See EsLdapExamples class>> exampleDeleteThenRestoreAttribute)
deleteAttribute: aString
Delete the attribute named aString from the entry. (See EsLdapExamples class>> exampleDeleteThenRestoreAttribute.)
getAllChildrenFilter: aString
Answer all children entries with all attributes according to the filter defined in aString. (See EsLdapExamples class>> exampleGetRootEntryExampleChildrenAllFilter.)
getAllChildrenFilter: aString attributes: aCollection
Answer all children entries with the attributes named in aCollection according to the filter defined in aString. (See EsLdapExamples class>> exampleGetRootEntryExampleChildrenAllFilterAndAttributes.)
getDirectChildrenFilter: aString
Answer the direct children of the LdpEntry all of whose attributes match a filter defined in aString. (See EsLdapExamples class>> exampleGetRootEntryExampleChildrenDirectFilter.)
getDirectChildrenFilter: aString attributes: aCollection
Answer the direct children of the LdapEentry whose attributes named in aCollection match the filter defined in aString. (See EsLdapExamples class>> exampleGetRootEntryExampleChildrenDirectFilterAndAttributes.)
getParentWithAttributes: aCollection
Answer the parent entry with the attributes given by aCollection matching a filter defined in aString. (See EsLdapExamples class>> exampleGetParentWithAttributes.)
delete –
Delete the LdapEntry from the directory. (See EsLdapExamples class>> exampleEdisonRemoveFromPeons.)
moveToNewParentDistinguishedName: newParentDNString
Move the entry to a new parent named newParentDNString. (See EsLdapExamples class>> exampleEdisonMoveToPeons.)
Finally, the LdapEntry class method createNewDistinguishedName:attributes:session: creates a new LDAP entry with distinguishedName aDNString and the attributes in aDictionary in the context of aLdapSession. (See EsLdapExamples class exampleEdisonAdd.)
Note
Adding, changing, or modifying LDAP entries may require a higher level of security on your LDAP server than just simple searching.
 
Last modified date: 05/25/2018