com.ibm.itim.remoteservices.provider
Class SearchResult

java.lang.Object
  |
  +--com.ibm.itim.remoteservices.provider.SearchResult
All Implemented Interfaces:
java.io.Serializable

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

Encapsulates an entry returned from a search on a remote resource. A search result corresponds to a single entity within TIM. For example, when communicating with a database a SearchResult would correspond to a row of the database, which may then be imported to TIM as an account or a person.

TIM will determine the type of entry to add based the object classes. If the object classes do not include the type expected for this service profile, then the entry will be interpreted as supporting data. For example, when reconciling accounts, each account entry must include the object class for that service and other entries, such as group data, will be added as supporting data.

Only attributes that are meaningful to the user should be added here. Users of this class should not add attributes that are used only for internal management by TIM at this point. For example, attributes like erglobalid. These will be added by the TIM dataservices framework elsewhere.

See Also:
Serialized Form

Constructor Summary
SearchResult(java.lang.String dn, java.util.Collection objectClasses, AttributeValues attributeValues)
          Creates new SearchResult
SearchResult(java.lang.String dn, java.lang.String objectClass, AttributeValues attributeValues)
          Creates new SearchResult
 
Method Summary
 AttributeValues getAttributeValues()
          Gets the model attributes for this search entry
 java.lang.String getDN()
          Gets the distinguished name for this search result
 java.lang.String getObjectClass()
          Gets the first object class or null if there isn't one
 java.util.Collection getObjectClasses()
          Gets the object classes for this search entry
 java.lang.String toString()
          Overrides the method from java.lang.Object.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SearchResult

public SearchResult(java.lang.String dn,
                    java.util.Collection objectClasses,
                    AttributeValues attributeValues)
Creates new SearchResult
Parameters:
dn - the distinguished name for this entry
objectClasses - One or more object classes for the entry
attributeValues - The attributes of the search entry

SearchResult

public SearchResult(java.lang.String dn,
                    java.lang.String objectClass,
                    AttributeValues attributeValues)
Creates new SearchResult
Parameters:
dn - the distinguished name for this entry
objectClass - Single object class for the entry
attributeValues - The attributes of the search entry
Method Detail

getDN

public java.lang.String getDN()
Gets the distinguished name for this search result
Returns:
the distinguished name for this search result

getAttributeValues

public AttributeValues getAttributeValues()
Gets the model attributes for this search entry
Returns:
model attributes

getObjectClasses

public java.util.Collection getObjectClasses()
Gets the object classes for this search entry
Returns:
object classes

getObjectClass

public java.lang.String getObjectClass()
Gets the first object class or null if there isn't one
Returns:
the first object class

toString

public java.lang.String toString()
Overrides the method from java.lang.Object.
Overrides:
toString in class java.lang.Object
Returns:
the name of the class, the dn, and the object classes.