|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.unboundid.ldap.sdk.migrate.ldapjdk.LDAPAttributeSet
@NotExtensible @Mutable @ThreadSafety(level=NOT_THREADSAFE) public class LDAPAttributeSet
This class provides a data structure that contains a set of LDAP attribute
objects.
This class is primarily intended to be used in the process of updating
applications which use the Netscape Directory SDK for Java to switch to or
coexist with the UnboundID LDAP SDK for Java. For applications not written
using the Netscape Directory SDK for Java, arrays or collections of
Attribute
objects should be used instead.
Constructor Summary | |
---|---|
LDAPAttributeSet()
Creates a new LDAP attribute set with no attributes. |
|
LDAPAttributeSet(LDAPAttribute[] attrs)
Creates a new LDAP attribute set with the provided attributes. |
Method Summary | |
---|---|
void |
add(LDAPAttribute attr)
Adds the provided attribute to this attribute set. |
LDAPAttributeSet |
duplicate()
Creates a duplicate of this attribute set. |
LDAPAttribute |
elementAt(int index)
Retrieves the attribute at the specified position in this attribute set. |
LDAPAttribute |
getAttribute(java.lang.String attrName)
Retrieves the attribute from this set whose name exactly matches the provided name. |
LDAPAttribute |
getAttribute(java.lang.String attrName,
java.lang.String lang)
Retrieves the attribute with the specified base name and the specified language subtype. |
java.util.Enumeration<LDAPAttribute> |
getAttributes()
Retrieves an enumeration of the attributes in this set. |
LDAPAttributeSet |
getSubset(java.lang.String subtype)
Retrieves a subset of the attributes in this attribute set which contain the specified subtype. |
void |
remove(java.lang.String name)
Removes the attribute with the specified name. |
void |
removeElementAt(int index)
Removes the attribute at the specified position in this attribute set. |
int |
size()
Retrieves the number of attributes contained in this attribute set. |
java.lang.String |
toString()
Retrieves a string representation of this attribute set. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public LDAPAttributeSet()
public LDAPAttributeSet(LDAPAttribute[] attrs)
attrs
- The set of attributes to include in the set.Method Detail |
---|
public java.util.Enumeration<LDAPAttribute> getAttributes()
public LDAPAttributeSet getSubset(java.lang.String subtype)
subtype
- The subtype for which to retrieve all of the attributes.
public LDAPAttribute getAttribute(java.lang.String attrName)
attrName
- The name of the attribute to retrieve.
null
if there is no such
attribute in this set.public LDAPAttribute getAttribute(java.lang.String attrName, java.lang.String lang)
attrName
- The base name for the attribute to retrieve.lang
- The language subtype to retrieve, or null
if
there should not be a language subtype.
null
if there is no such attribute.public LDAPAttribute elementAt(int index) throws java.lang.IndexOutOfBoundsException
index
- The position of the attribute to retrieve.
java.lang.IndexOutOfBoundsException
- If the provided index invalid.public void add(LDAPAttribute attr)
attr
- The attribute to be added to this set.public void remove(java.lang.String name)
name
- The name of the attribute to remove.public void removeElementAt(int index) throws java.lang.IndexOutOfBoundsException
index
- The position of the attribute to remove.
java.lang.IndexOutOfBoundsException
- If the provided index is invalid.public int size()
public LDAPAttributeSet duplicate()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |