com.ibm.di.connector.ccmdb
Class CIRelationDataHandler

java.lang.Object
  extended by com.ibm.di.connector.ccmdb.AbstractDataHandler
      extended by com.ibm.di.connector.ccmdb.CIRelationDataHandler

public class CIRelationDataHandler
extends AbstractDataHandler

An implementation of AbstrcatDataHander that is designed to work with relationships.


Field Summary
 
Fields inherited from class com.ibm.di.connector.ccmdb.AbstractDataHandler
ALL, ctx
 
Constructor Summary
CIRelationDataHandler()
           
 
Method Summary
 boolean addEntry(Entry entry)
          Inserts an instance of selected artifact type into the data store.
 Entry getNextEntry()
          This method returns a single entry object for a selected artifact instance, searched as per criteria.
 Entry getSchema()
          Returns the schema that is based on selected artifact type and class name.
 void init(ExecutionContext context)
           
 boolean removeEntry(Entry entry)
          Removes an instance of selected artifact type from the data store.
 void selectEntries()
          This method will fetch instances of selected artifact type.
 void setSearchCriteria(SearchCriteria criteria)
          Sets the search criteria used in select operation.
 boolean updateEntry(Entry entry)
          Updates an instance of selected artifact type in the database.
 
Methods inherited from class com.ibm.di.connector.ccmdb.AbstractDataHandler
getClassifications
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CIRelationDataHandler

public CIRelationDataHandler()
Method Detail

init

public void init(ExecutionContext context)
Overrides:
init in class AbstractDataHandler
Parameters:
context - the executionContext instance associated with the current execution.

getSchema

public Entry getSchema()
                throws CCMDBException
Description copied from class: AbstractDataHandler
Returns the schema that is based on selected artifact type and class name.

Specified by:
getSchema in class AbstractDataHandler
Returns:
Entry The schema.
Throws:
CCMDBException - if a problem occurs.

getNextEntry

public Entry getNextEntry()
                   throws CCMDBException
Description copied from class: AbstractDataHandler
This method returns a single entry object for a selected artifact instance, searched as per criteria.

Specified by:
getNextEntry in class AbstractDataHandler
Returns:
Entry the next read entry.
Throws:
CCMDBException - if a problem occurs.

setSearchCriteria

public void setSearchCriteria(SearchCriteria criteria)
                       throws CCMDBException
Description copied from class: AbstractDataHandler
Sets the search criteria used in select operation.

Specified by:
setSearchCriteria in class AbstractDataHandler
Parameters:
criteria - SearchCriteria object provided by CE
Throws:
CCMDBException - if a problem occurs.

selectEntries

public void selectEntries()
                   throws CCMDBException
Description copied from class: AbstractDataHandler
This method will fetch instances of selected artifact type. The selection is based on selected class name and search criteria that has been set.

Specified by:
selectEntries in class AbstractDataHandler
Throws:
CCMDBException - if a problem occurs.

addEntry

public boolean addEntry(Entry entry)
                 throws CCMDBException
Description copied from class: AbstractDataHandler
Inserts an instance of selected artifact type into the data store.

Specified by:
addEntry in class AbstractDataHandler
Parameters:
entry - the Entry to be added.
Returns:
boolean indicates if the entry has been added successfully.
Throws:
CCMDBException - if a problem occurs.

updateEntry

public boolean updateEntry(Entry entry)
                    throws CCMDBException
Description copied from class: AbstractDataHandler
Updates an instance of selected artifact type in the database. The instance attributes are extracted from an input entry.

Specified by:
updateEntry in class AbstractDataHandler
Parameters:
entry - The Entry to be updated.
Returns:
boolean indicates if the specified artifact has been updated successfully.
Throws:
CCMDBException - if a problem occurs.

removeEntry

public boolean removeEntry(Entry entry)
                    throws CCMDBException
Description copied from class: AbstractDataHandler
Removes an instance of selected artifact type from the data store. The instance is identified based on an input entry.

Specified by:
removeEntry in class AbstractDataHandler
Parameters:
entry - the Entry to be deleted.
Returns:
boolean indicates if the specified artifact has been deleted successfully.
Throws:
CCMDBException - if a problem occurs.