Class NT4UserMetaDataConnector

    • Field Detail

      • PARAM_COMPUTER_NAME

        public static final java.lang.String PARAM_COMPUTER_NAME
        Connector`s parameter name
        See Also:
        Constant Field Values
      • PARAM_USER_NAME

        public static final java.lang.String PARAM_USER_NAME
        Connector`s parameter name
        See Also:
        Constant Field Values
      • PARAM_PASSWORD

        public static final java.lang.String PARAM_PASSWORD
        Connector`s parameter name
        See Also:
        Constant Field Values
      • PARAM_ENTRY_TYPE

        public static final java.lang.String PARAM_ENTRY_TYPE
        Connector`s parameter name
        See Also:
        Constant Field Values
      • PARAM_PAGE_SIZE

        public static final java.lang.String PARAM_PAGE_SIZE
        Connector`s parameter name
        See Also:
        Constant Field Values
      • PARAM_VALUE_ENTRY_USER

        public static final java.lang.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 java.lang.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​(java.lang.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.
      • 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 java.lang.Object querySchema​(java.lang.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 java.lang.String getVersion()
        Version information.
        Specified by:
        getVersion in interface VersionInfoInterface
        Returns:
        version information.