com.ibm.di.connector.NT4UserMetaDataConnector
Class NT4UserMetaDataConnector

java.lang.Object
  extended by com.ibm.di.connector.Connector
      extended by com.ibm.di.connector.NT4UserMetaDataConnector.NT4UserMetaDataConnector
All Implemented Interfaces:
ConnectorInterface, VersionInfoInterface

public class NT4UserMetaDataConnector
extends Connector
implements ConnectorInterface

This class represents a Connector for managing Windows User and Group accounts.


Field Summary
static int MAX_PAGE_SIZE
          Active Directory maximup "page size" for the "NetQueryDisplayInformation"
static String PARAM_COMPUTER_NAME
          Connector`s parameter name
static String PARAM_ENTRY_TYPE
          Connector`s parameter name
static String PARAM_PAGE_SIZE
          Connector`s parameter name
static String PARAM_PASSWORD
          Connector`s parameter name
static String PARAM_USER_NAME
          Connector`s parameter name
static String PARAM_VALUE_ENTRY_GROUP
          Value for the PARAM_ENTRY_TYPE connector's parameter
static String PARAM_VALUE_ENTRY_USER
          Value for the PARAM_ENTRY_TYPE connector's parameter
 
Fields inherited from class com.ibm.di.connector.Connector
ALL_MODES, myLog, PROPERTY_MESSAGE, PROPERTY_READER, PROPERTY_WRITER
 
Constructor Summary
NT4UserMetaDataConnector()
          Class constructor
 
Method Summary
 void deleteEntry(Entry aEntry, SearchCriteria aRscSearchCriteria)
          Deletes given entry (user or group) from Windows security database.
 Entry findEntry(SearchCriteria aRscSearchCriteria)
          Retrieves a single entry object matching the given search criteria parameter.
 Entry getNextEntry()
          Retrieves the next entry from the connector's containers.
 String getVersion()
          Version information.
 void initialize(Object aObj)
          Reads connector parameters' values.
 void modEntry(Entry aEntry, SearchCriteria aRscSearchCriteria)
          Modifies in Windows database the entry identified by the aRscSearchCriteria parameter with the data given in the aEntry parameter.
 void putEntry(Entry aEntry)
          Inserts given entry (user or group) into Windows security database.
 Object querySchema(Object aObj)
          Retrieves connector entry's structure.
 void selectEntries()
          Reads all entries from Windows security database in a connector's container.
 
Methods inherited from class com.ibm.di.connector.Connector
addFindEntry, allModes, clearFindEntries, debug, debugMode, findEntry, getBoolean, getClassInstance, getConfiguration, getContext, getFindEntryCount, getFirstFindEntry, getLog, getMaxDuplicateEntries, getModes, getModes, getName, getNextClient, getNextFindEntry, getParam, getParser, getProperty, getPushbackEntry, getRawConnectorConfiguration, getRSInterface, getUI, hasConfigValue, hasParser, initParser, isDeltaSupported, isExceptionFatal, isIOException, logError, logmsg, modEntry, pushback, queryOperations, queryReply, queryTables, reconnect, reconnect, registerScriptBeans, replyEntry, setConfiguration, setContext, setCurrent, setDebugMode, setLog, setMaxDuplicateEntries, setModes, setModes, setName, setParam, setParser, setProperty, setRSInterface, terminate, terminateServer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ibm.di.connector.ConnectorInterface
getConfiguration, getContext, getFindEntryCount, getFirstFindEntry, getMaxDuplicateEntries, getName, getNextClient, getNextFindEntry, getParam, getPushbackEntry, getRawConnectorConfiguration, isDeltaSupported, isExceptionFatal, isIOException, modEntry, pushback, queryOperations, queryReply, reconnect, registerScriptBeans, replyEntry, setConfiguration, setContext, setCurrent, setLog, setMaxDuplicateEntries, setName, setParam, setRSInterface, terminate, terminateServer
 

Field Detail

PARAM_COMPUTER_NAME

public static final String PARAM_COMPUTER_NAME
Connector`s parameter name

See Also:
Constant Field Values

PARAM_USER_NAME

public static final String PARAM_USER_NAME
Connector`s parameter name

See Also:
Constant Field Values

PARAM_PASSWORD

public static final String PARAM_PASSWORD
Connector`s parameter name

See Also:
Constant Field Values

PARAM_ENTRY_TYPE

public static final String PARAM_ENTRY_TYPE
Connector`s parameter name

See Also:
Constant Field Values

PARAM_PAGE_SIZE

public static final String PARAM_PAGE_SIZE
Connector`s parameter name

See Also:
Constant Field Values

PARAM_VALUE_ENTRY_USER

public static final String PARAM_VALUE_ENTRY_USER
Value for the PARAM_ENTRY_TYPE connector's parameter

See Also:
Constant Field Values

PARAM_VALUE_ENTRY_GROUP

public static final String PARAM_VALUE_ENTRY_GROUP
Value for the PARAM_ENTRY_TYPE connector's parameter

See Also:
Constant Field Values

MAX_PAGE_SIZE

public static final int MAX_PAGE_SIZE
Active Directory maximup "page size" for the "NetQueryDisplayInformation"

See Also:
Constant Field Values
Constructor Detail

NT4UserMetaDataConnector

public NT4UserMetaDataConnector()
Class constructor

Method Detail

initialize

public void initialize(Object aObj)
                throws NT4UserMetaDataException
Reads connector parameters' values. If UserName parameter is set tries to log on to the machine indicated by the ComputerName parameter.

Specified by:
initialize in interface ConnectorInterface
Overrides:
initialize in class Connector
Parameters:
aObj - This parameter is usually null but can be any type of object the caller chooses to passon. Normally the parameter is some kind of input stream or Reader object.
Throws:
NT4UserMetaDataException - If bad parameter values are given.

selectEntries

public void selectEntries()
                   throws NT4UserMetaDataException
Reads all entries from Windows security database in a connector's container. Depending on the value of EntryType connector's parameter this method dispatches the execution to either selectUserEntries or selectGroupEntries method.

Specified by:
selectEntries in interface ConnectorInterface
Overrides:
selectEntries in class Connector
Throws:
NT4UserMetaDataException - If an error occurs while obtaining data from Windows database.

getNextEntry

public Entry getNextEntry()
                   throws NT4UserMetaDataException
Retrieves the next entry from the connector's containers. Depending on the value of EntryType connector's parameter this method dispatches the execution to either getNextUserEntry or getNextGroupEntry method.

Specified by:
getNextEntry in interface ConnectorInterface
Overrides:
getNextEntry in class Connector
Returns:
The consecutive Entry object.
Throws:
NT4UserMetaDataException - If an error occurs while obtaining data from Windows database or the EntryType value is invalid.
See Also:
ConnectorInterface.selectEntries()

findEntry

public Entry findEntry(SearchCriteria aRscSearchCriteria)
                throws NT4UserMetaDataException
Retrieves a single entry object matching the given search criteria parameter. Depending on the value of EntryType connector's parameter this method dispatches the execution to either findUserEntry or findGroupEntry method.

Specified by:
findEntry in interface ConnectorInterface
Overrides:
findEntry in class Connector
Parameters:
aRscSearchCriteria - The search criteria to locate the entry. Should contain just one rscSearch element (holding the entry's account name value) when operating with Users and two rscSearch elements (1st - group's account name and 2nd - global/local indicator) when operating with Groups.
Returns:
Entry
Throws:
NT4UserMetaDataException - If an error occurs while obtaining data from Windows database. If unsupported search criteria is given.

putEntry

public void putEntry(Entry aEntry)
              throws NT4UserMetaDataException
Inserts given entry (user or group) into Windows security database. Depending on the value of EntryType connector's parameter this method dispatches the execution to either putUser or putGroup method.

Specified by:
putEntry in interface ConnectorInterface
Overrides:
putEntry in class Connector
Parameters:
aEntry - The Entry object to be inserted.
Throws:
NT4UserMetaDataException - If an error occurs while inserting data into Windows database.

modEntry

public void modEntry(Entry aEntry,
                     SearchCriteria aRscSearchCriteria)
              throws NT4UserMetaDataException
Modifies in Windows database the entry identified by the aRscSearchCriteria parameter with the data given in the aEntry parameter. Depending on the value of EntryType connector's parameter this method dispatches the execution to either modUserEntry or modGroupEntry method.

Specified by:
modEntry in interface ConnectorInterface
Overrides:
modEntry in class Connector
Parameters:
aEntry - Entry object containing the new data.
aRscSearchCriteria - The search criteria used by the assembly line to locate this entry.
Throws:
NT4UserMetaDataException - If an error occurs while modifying data into Windows database.

deleteEntry

public void deleteEntry(Entry aEntry,
                        SearchCriteria aRscSearchCriteria)
                 throws NT4UserMetaDataException
Deletes given entry (user or group) from Windows security database. Depending on the value of EntryType connector's parameter this method dispatches the execution to either deleteUserEntry or deleteGroupEntry method.

Specified by:
deleteEntry in interface ConnectorInterface
Overrides:
deleteEntry in class Connector
Parameters:
aEntry - The entry object to be deleted.
aRscSearchCriteria - The search criteria used by the assembly line to locate this entry.
Throws:
NT4UserMetaDataException - If an error occured while deleting data from Windows database.

querySchema

public Object querySchema(Object aObj)
                   throws NT4UserMetaDataException
Retrieves connector entry's structure. Depending on the value of EntryType connector's parameter this method dispatches the execution to either UserInfo.queryUserSchema or GroupInfo.queryGroupSchema method.

Specified by:
querySchema in interface ConnectorInterface
Overrides:
querySchema in class Connector
Parameters:
aObj - Object
Returns:
Vector of elements of type Entry describing each attribute's structure.
Throws:
NT4UserMetaDataException - If the value of the private member mEntryType is invalid.
See Also:
Entry, Vector

getVersion

public String getVersion()
Version information.

Specified by:
getVersion in interface VersionInfoInterface
Returns:
version information.