Methods Summary |
---|
public void | add(int ix, java.lang.Object attrVal)Adds an attribute value to the ordered list of attribute values.
This method adds attrVal to the list of attribute values at
index ix.
Values located at indices at or greater than ix are
shifted down towards the end of the list (and their indices incremented
by one).
If the attribute values are unordered and already have attrVal,
IllegalStateException is thrown.
|
public boolean | add(java.lang.Object attrVal)Adds a new value to the attribute.
If the attribute values are unordered and
attrVal is already in the attribute, this method does nothing.
If the attribute values are ordered, attrVal is added to the end of
the list of attribute values.
Equality is determined by the implementation, which may use
Object.equals() or schema information to determine equality.
|
public void | clear()Removes all values from this attribute.
|
public java.lang.Object | clone()Makes a copy of the attribute.
The copy contains the same attribute values as the original attribute:
the attribute values are not themselves cloned.
Changes to the copy will not affect the original and vice versa.
|
public boolean | contains(java.lang.Object attrVal)Determines whether a value is in the attribute.
Equality is determined by the implementation, which may use
Object.equals() or schema information to determine equality.
|
public java.lang.Object | get(int ix)Retrieves the attribute value from the ordered list of attribute values.
This method returns the value at the ix index of the list of
attribute values.
If the attribute values are unordered,
this method returns the value that happens to be at that index.
|
public java.lang.Object | get()Retrieves one of this attribute's values.
If the attribute has more than one value and is unordered, any one of
the values is returned.
If the attribute has more than one value and is ordered, the
first value is returned.
|
public javax.naming.NamingEnumeration | getAll()Retrieves an enumeration of the attribute's values.
The behaviour of this enumeration is unspecified
if the attribute's values are added, changed,
or removed while the enumeration is in progress.
If the attribute values are ordered, the enumeration's items
will be ordered.
|
public javax.naming.directory.DirContext | getAttributeDefinition()Retrieves the attribute's schema definition.
An attribute's schema definition contains information
such as whether the attribute is multivalued or single-valued,
the matching rules to use when comparing the attribute's values.
The information that you can retrieve from an attribute definition
is directory-dependent.
If an implementation does not support schemas, it should throw
OperationNotSupportedException. If an implementation does support
schemas, it should define this method to return the appropriate
information.
|
public javax.naming.directory.DirContext | getAttributeSyntaxDefinition()Retrieves the syntax definition associated with the attribute.
An attribute's syntax definition specifies the format
of the attribute's value(s). Note that this is different from
the attribute value's representation as a Java object. Syntax
definition refers to the directory's notion of syntax.
For example, even though a value might be
a Java String object, its directory syntax might be "Printable String"
or "Telephone Number". Or a value might be a byte array, and its
directory syntax is "JPEG" or "Certificate".
For example, if this attribute's syntax is "JPEG",
this method would return the syntax definition for "JPEG".
The information that you can retrieve from a syntax definition
is directory-dependent.
If an implementation does not support schemas, it should throw
OperationNotSupportedException. If an implementation does support
schemas, it should define this method to return the appropriate
information.
|
public java.lang.String | getID()Retrieves the id of this attribute.
|
public boolean | isOrdered()Determines whether this attribute's values are ordered.
If an attribute's values are ordered, duplicate values are allowed.
If an attribute's values are unordered, they are presented
in any order and there are no duplicate values.
|
public java.lang.Object | remove(int ix)Removes an attribute value from the ordered list of attribute values.
This method removes the value at the ix index of the list of
attribute values.
If the attribute values are unordered,
this method removes the value that happens to be at that index.
Values located at indices greater than ix are shifted up towards
the front of the list (and their indices decremented by one).
|
public boolean | remove(java.lang.Object attrval)Removes a specified value from the attribute.
If attrval is not in the attribute, this method does nothing.
If the attribute values are ordered, the first occurrence of
attrVal is removed and attribute values at indices greater
than the removed
value are shifted up towards the head of the list (and their indices
decremented by one).
Equality is determined by the implementation, which may use
Object.equals() or schema information to determine equality.
|
public java.lang.Object | set(int ix, java.lang.Object attrVal)Sets an attribute value in the ordered list of attribute values.
This method sets the value at the ix index of the list of
attribute values to be attrVal. The old value is removed.
If the attribute values are unordered,
this method sets the value that happens to be at that index
to attrVal, unless attrVal is already one of the values.
In that case, IllegalStateException is thrown.
|
public int | size()Retrieves the number of values in this attribute.
|