|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.directory.server.core.entry.ServerEntryUtils
public class ServerEntryUtils
A helper class used to manipulate Entries, Attributes and Values.
| Constructor Summary | |
|---|---|
ServerEntryUtils()
|
|
| Method Summary | |
|---|---|
static java.util.List<org.apache.directory.shared.ldap.entry.Modification> |
convertToServerModification(java.util.List<javax.naming.directory.ModificationItem> modificationItems,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
Convert a list of ModificationItemImpl to a list of |
static org.apache.directory.shared.ldap.entry.EntryAttribute |
getAttribute(java.util.List<org.apache.directory.shared.ldap.entry.Modification> mods,
org.apache.directory.shared.ldap.schema.AttributeType type)
Utility method to extract an attribute from a list of modifications. |
static org.apache.directory.shared.ldap.entry.Modification |
getModificationItem(java.util.List<org.apache.directory.shared.ldap.entry.Modification> mods,
org.apache.directory.shared.ldap.schema.AttributeType type)
Utility method to extract a modification item from an array of modifications. |
static org.apache.directory.shared.ldap.entry.ServerEntry |
getTargetEntry(org.apache.directory.shared.ldap.entry.Modification mod,
org.apache.directory.shared.ldap.entry.ServerEntry entry,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
Gets the target entry as it would look after a modification operation was performed on it. |
static org.apache.directory.shared.ldap.entry.EntryAttribute |
getUnion(org.apache.directory.shared.ldap.entry.EntryAttribute attr0,
org.apache.directory.shared.ldap.entry.EntryAttribute attr1)
Creates a new attribute which contains the values representing the union of two attributes. |
static javax.naming.directory.Attribute |
toBasicAttribute(org.apache.directory.shared.ldap.entry.EntryAttribute entryAttribute)
Convert a ServerAttribute into a BasicAttribute. |
static javax.naming.directory.Attributes |
toBasicAttributes(org.apache.directory.shared.ldap.entry.ServerEntry entry)
Convert a ServerEntry into a BasicAttributes. |
static javax.naming.NamingEnumeration<javax.naming.directory.SearchResult> |
toSearchResultEnum(javax.naming.NamingEnumeration<ServerSearchResult> result)
Encapsulate a ServerSearchResult enumeration into a SearchResult enumeration |
static org.apache.directory.shared.ldap.entry.EntryAttribute |
toServerAttribute(javax.naming.directory.Attribute attribute,
org.apache.directory.shared.ldap.schema.AttributeType attributeType)
Convert a BasicAttribute or a AttributeImpl to a ServerAtribute |
static org.apache.directory.shared.ldap.entry.ServerEntry |
toServerEntry(javax.naming.directory.Attributes attributes,
org.apache.directory.shared.ldap.name.DN dn,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
Convert a BasicAttributes or a AttributesImpl to a ServerEntry |
static java.util.List<org.apache.directory.shared.ldap.entry.Modification> |
toServerModification(org.apache.directory.shared.ldap.entry.Modification[] modifications,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
|
static java.util.List<org.apache.directory.shared.ldap.entry.Modification> |
toServerModification(javax.naming.directory.ModificationItem[] modifications,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ServerEntryUtils()
| Method Detail |
|---|
public static javax.naming.directory.Attribute toBasicAttribute(org.apache.directory.shared.ldap.entry.EntryAttribute entryAttribute)
public static javax.naming.directory.Attributes toBasicAttributes(org.apache.directory.shared.ldap.entry.ServerEntry entry)
public static org.apache.directory.shared.ldap.entry.EntryAttribute toServerAttribute(javax.naming.directory.Attribute attribute,
org.apache.directory.shared.ldap.schema.AttributeType attributeType)
attribute - the BasicAttributes or AttributesImpl instance to convertattributeType -
javax.naming.directory.InvalidAttributeIdentifierException - If we had an incorrect attribute
public static org.apache.directory.shared.ldap.entry.ServerEntry toServerEntry(javax.naming.directory.Attributes attributes,
org.apache.directory.shared.ldap.name.DN dn,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
throws org.apache.directory.shared.ldap.exception.LdapInvalidAttributeTypeException
attributes - the BasicAttributes or AttributesImpl instance to convertregistries - The registries, needed ro build a ServerEntrydn - The DN which is needed by the ServerEntry
org.apache.directory.shared.ldap.exception.LdapInvalidAttributeTypeException - If we get an invalid attribute
public static org.apache.directory.shared.ldap.entry.ServerEntry getTargetEntry(org.apache.directory.shared.ldap.entry.Modification mod,
org.apache.directory.shared.ldap.entry.ServerEntry entry,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
throws org.apache.directory.shared.ldap.exception.LdapException
mod - the modificationentry - the source entry that is modified
org.apache.directory.shared.ldap.exception.LdapException - if there are problems accessing attributes
public static org.apache.directory.shared.ldap.entry.EntryAttribute getUnion(org.apache.directory.shared.ldap.entry.EntryAttribute attr0,
org.apache.directory.shared.ldap.entry.EntryAttribute attr1)
IllegalArgumentException
is raised.
attr0 - the first attributeattr1 - the second attribute
org.apache.directory.shared.ldap.exception.LdapException - if there are problems accessing attribute values
public static java.util.List<org.apache.directory.shared.ldap.entry.Modification> convertToServerModification(java.util.List<javax.naming.directory.ModificationItem> modificationItems,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
throws org.apache.directory.shared.ldap.exception.LdapException
modificationImpls - atRegistry -
org.apache.directory.shared.ldap.exception.LdapException
public static java.util.List<org.apache.directory.shared.ldap.entry.Modification> toServerModification(org.apache.directory.shared.ldap.entry.Modification[] modifications,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
throws org.apache.directory.shared.ldap.exception.LdapException
org.apache.directory.shared.ldap.exception.LdapException
public static java.util.List<org.apache.directory.shared.ldap.entry.Modification> toServerModification(javax.naming.directory.ModificationItem[] modifications,
org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
throws org.apache.directory.shared.ldap.exception.LdapException
org.apache.directory.shared.ldap.exception.LdapException
public static final org.apache.directory.shared.ldap.entry.Modification getModificationItem(java.util.List<org.apache.directory.shared.ldap.entry.Modification> mods,
org.apache.directory.shared.ldap.schema.AttributeType type)
mods - the array of ModificationItems to extract the Attribute from.type - the attributeType spec of the Attribute to extract
public static org.apache.directory.shared.ldap.entry.EntryAttribute getAttribute(java.util.List<org.apache.directory.shared.ldap.entry.Modification> mods,
org.apache.directory.shared.ldap.schema.AttributeType type)
mods - the list of ModificationItems to extract the Attribute from.type - the attributeType spec of the Attribute to extract
public static javax.naming.NamingEnumeration<javax.naming.directory.SearchResult> toSearchResultEnum(javax.naming.NamingEnumeration<ServerSearchResult> result)
result - The ServerSearchResult enumeration
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||