Skip navigation links

Oracle Internet Directory API Reference
11g Release 1 (11.1.1)

E10664-01


oracle.ldap.util
Class PropertySetCollection

java.lang.Object
  extended by oracle.ldap.util.PropertySetCollection

All Implemented Interfaces:
java.io.Serializable

public class PropertySetCollection
extends java.lang.Object
implements java.io.Serializable

This class represents a collection of PropertySets. In other words, it represents a set of search result entries from a given search.

See Also:
Serialized Form

Constructor Summary
protected PropertySetCollection()
           
  PropertySetCollection(int initSize)
           
protected PropertySetCollection(java.lang.String base, java.lang.Object inResultSet)
           
protected PropertySetCollection(java.lang.String base, java.lang.Object inResultSet, boolean convert)
           

 

Method Summary
 void addPropertySet(PropertySet propSet)
           
 void convert()
           
 java.lang.String[] getDns()
          Returns an array of String containing the name of all the property sets - the DN's of all the search entries in this search result.
 PropertySet getPropertySet(int i)
          Returns the i-th property set of this property set collection - the i-th search entry of this search result.
 PropertySet getPropertySet(java.lang.String dn)
          Returns the property set identified by dn - the search entry with the given DN
 java.lang.String[] getPropertyValues(java.lang.String propName)
          getPropertyValues This function provides a short cut for caller to retrieve string values of a specific property from the PropertySetCollection.
 java.lang.String getUniquePropertyValue(java.lang.String propName)
           Provides a short cut for caller to retrieve value of a specific property from the PropertySetCollection.
 boolean isEmpty()
          Returns true if the property set collection does not contain any property set; false otherwise
 boolean isSizeLimitExceeded()
          Returns true if sizelimit is exceeded for during the query from which this PropertySetCollection is generated
 int size()
          Returns the size of the property set collection - the number of search entries in the search result

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

PropertySetCollection

protected PropertySetCollection()

PropertySetCollection

public PropertySetCollection(int initSize)

PropertySetCollection

protected PropertySetCollection(java.lang.String base,
                                java.lang.Object inResultSet)

PropertySetCollection

protected PropertySetCollection(java.lang.String base,
                                java.lang.Object inResultSet,
                                boolean convert)

Method Detail

isEmpty

public final boolean isEmpty()
Returns true if the property set collection does not contain any property set; false otherwise
Returns:
boolean indicating whether the property set is empty or not

size

public final int size()
Returns the size of the property set collection - the number of search entries in the search result
Returns:
an int indicating the number of property sets in the collection -

isSizeLimitExceeded

public final boolean isSizeLimitExceeded()
Returns true if sizelimit is exceeded for during the query from which this PropertySetCollection is generated
Returns:
true if sizelimit is exceeded. Otherwise false

addPropertySet

public void addPropertySet(PropertySet propSet)

getDns

public final java.lang.String[] getDns()
Returns an array of String containing the name of all the property sets - the DN's of all the search entries in this search result.
Returns:
a String array containing all the property set names.

getPropertySet

public final PropertySet getPropertySet(int i)
Returns the i-th property set of this property set collection - the i-th search entry of this search result.
Parameters:
i - the index of the property set to be retrieved
Returns:
a PropertySet representing the i-th property set.

getPropertySet

public final PropertySet getPropertySet(java.lang.String dn)
Returns the property set identified by dn - the search entry with the given DN
Parameters:
dn - the DN of the property set to be retrieved
Returns:
a PropertySet with given dn.

convert

public void convert()

getPropertyValues

public java.lang.String[] getPropertyValues(java.lang.String propName)
                                     throws UtilException
getPropertyValues This function provides a short cut for caller to retrieve string values of a specific property from the PropertySetCollection. All values from matching Property(s) will be retrieved.
Parameters:
propName - - Name of the attribute/property
Returns:
String[] - array of values retrieved for the specified property in all PropertySet.
Throws:
UtilException - - when the PropertySetCollection is empty - when the specified property does not have value. CastException - when the property has non-string value

getUniquePropertyValue

public java.lang.String getUniquePropertyValue(java.lang.String propName)
                                        throws UtilException

Provides a short cut for caller to retrieve value of a specific property from the PropertySetCollection. The property must be unique among the collection of PropertySet(s). And it must be a single value attribute/property.

Parameters:
propName - - Name of the attribute/property.
Returns:
String - value of the specified property.
Throws:
UtilException - - when the PropertySetCollection is empty - when the specified property does not have value. - when there is more than 1 matching PropertySet. - when the specified property have more than 1 value.

Skip navigation links

Oracle Internet Directory API Reference
11g Release 1 (11.1.1)

E10664-01


Copyright © 1999, 2009 Oracle. All Rights Reserved.