com.waveset.adapter
Interface ResourceAdapter

All Known Implementing Classes:
ResourceAdapterBase, ResourceAdapterProxy, UnixResourceAdapter

public interface ResourceAdapter


Nested Class Summary
static interface ResourceAdapter.ActionResult
           
static interface ResourceAdapter.Features
           
static interface ResourceAdapter.ObjectType
          This nested interface enumerates constants for well-known values of "objectType".
 
Field Summary
static java.lang.String CHANGE_PASSWORD_LOCATION
          When this appears as an account attribute, it means that the user should change the password at the location specified as the attr value.
static java.lang.String code_id
           
static java.lang.String DISABLE
          The name of an attribute used to pass disable requests.
static java.lang.String ENABLE
          The name of an attribute used to pass enable requests.
static java.lang.String EXPIRE_PASSWORD
          When this appears as an account attribute, it means that the resource is to expire the password.
static java.lang.String GUID
          a GUID for a user resource account, populated by the adapter on create
static java.lang.String IGNORE_ATTR
          Scema map attributes with this as their "right hand" value will not be sent to the resource - they are a way to communicate with the resource adapter.
static java.lang.String NEW_ACCOUNT_ID
          When this appears as an account attribute, it means that the account should be renamed.
static java.lang.String OP_DAYS_INACTIVE
           
static java.lang.String OP_DISABLED
           
static java.lang.String OP_DORMANT
           
static java.lang.String OP_EXPIRED
           
static java.lang.String OP_EXPIREDPWD
           
static java.lang.String OP_INACTIVE
           
static java.lang.String OP_LOCKED
           
static java.lang.String OP_NO_PASSWORD_SET
           
static java.lang.String OP_NOOWNERSHIP
           
static java.lang.String OP_NOPASSWORDREQ
           
static java.lang.String OP_NUMINACTIVEDAYS
           
static java.lang.String OP_NUMPWDAYS
           
static java.lang.String OP_PWNUMDAYS
           
static java.lang.String RA_BASE_CTX
          The base context used when searching for and resolving names in a hierarchical namespace, if searchContext not specified.
static java.lang.String RA_DISPLAY_NAME_ATTR
          The name of a resource account attribute whose value will be used when displaying the name of this account (e.g.
static java.lang.String RA_NEW_OBJECT_ID
          When this appears as an object attribute, it means that the object should be renamed.
static java.lang.String RA_NEW_OBJECT_NAME
          When this appears as an object attribute, it means that the object should be renamed.
static java.lang.String RA_OBJECT_ATTRIBUTES
          object attributes container
static java.lang.String RA_OBJECT_CLASS
          object Class ** Note ** This name is not set to "objectClass" in order to maintain backward compataibility with the ADSI Resource and gateway use of the string "Object Class" for this resource attribute
static java.lang.String RA_OBJECT_ID
          object Id
static java.lang.String RA_OBJECT_TYPE
          object Type
static java.lang.String RA_OP_TYPE
          Can be used to indicate a specific type of operation is being sent to the RA.
static java.lang.String RA_RENAME_OP
          Rename operation.
static java.lang.String RA_REQUESTOR
          The resource specific id of the user making the request.
static java.lang.String RA_SAVEAS_OP
          Save As operation.
static java.lang.String RA_SEARCH_ATTRIBUTE_NAMES
          The set of one or more attribue names used when searching for and resolving names in a hierarchical namespace within a specified search container
static java.lang.String RA_SEARCH_ATTRS_TO_GET
          The set of one or more attribute names whose values should be returned in each object returned from a list / search request
static java.lang.String RA_SEARCH_CONTEXT
          The context used when searching for and resolving names in a hierarchical namespace
static java.lang.String RA_SEARCH_FILTER
          An optional search filter in LDAP filter format
static java.lang.String RA_SEARCH_RUN_AS_PASSWORD
           
static java.lang.String RA_SEARCH_RUN_AS_USER
          If specified, represent the user/password to authenticate to the resource with so all search operations will be performed running as the specified user and therefore scoped based on the user's access control on that resource.
static java.lang.String RA_SEARCH_SCOPE
          The depth of the search in a hierarchical namespace (e.g.
static java.lang.String RA_SEARCH_SCOPE_OBJECT
           
static java.lang.String RA_SEARCH_SCOPE_ONE_LEVEL
           
static java.lang.String RA_SEARCH_SCOPE_SUBTREE
           
static java.lang.String RA_SEARCH_TIME_LIMIT
          The timelimit in milliseconds a search should not exceed
static java.lang.String RESET_PASSWORD
          When this appears, it means that the resource is to reset the password.
static java.lang.String[] SYSTEM_ATTRIBUTES
          A collection of all builtin attributes.
static java.lang.String UNLOCK
          When this appears as an account attribute, it means that the resource is to unlock the user account.
static java.lang.String WS_USER_PASSWORD
          When this appears as an account attribute, it means that the change password should be done as the user using the user's current resource password whose value is in this attribute.
 
Method Summary
 WavesetResult authenticate(java.util.HashMap loginInfo)
          Authenticates the user against the resource.
 WavesetResult checkCreateAccount(WSUser user)
           
 WavesetResult checkDeleteAccount(WSUser user)
           
 WavesetResult checkUpdateAccount(WSUser user)
           
 WavesetResult createAccount(WSUser user)
           
 WavesetResult createAccounts(WSUser[] users)
           
 java.lang.String createIdentity(WSUser user)
           
 WavesetResult createObject(GenericObject object, java.util.Map options)
          Creates the specified objectId of type objectType using the list of attributes provided.
 Resource createPrototypeResource()
           
 WavesetResult deleteAccount(WSUser user)
           
 WavesetResult deleteAccount(WSUser user, long timeout)
          Delete the resource account specified by the input WSUser.
 WavesetResult deleteAccounts(WSUser[] users)
           
 WavesetResult deleteObject(GenericObject object, java.util.Map options)
          Deletes the requested objectId of the requested objectType from the resource
 WavesetResult disableAccount(WSUser user)
           
 WavesetResult disableAccounts(WSUser[] users)
           
 WavesetResult enableAccount(WSUser user)
           
 WavesetResult enableAccounts(WSUser[] users)
           
 WSAttributes getAccountAttributes(java.lang.String accountIdentity)
          This method is obsolete.
 AccountIterator getAccountIterator()
           
 AccountIterator getAccountIterator(long timeout)
           
 AccountIterator getAccountIterator(java.util.Map filterParams)
          Like getAccountIterator but takes a Map param.
 java.util.List getAllAccounts()
           
 java.lang.String getBaseContextAttrName()
          Deprecated. As of 4.0 use getBaseContexts().
 GenericObject getBaseContextObject(java.lang.String baseContext)
           
 java.util.List getBaseContexts()
          Needs to be overridden by subclass in order to support browsing and editing of resource objects
 GenericObject getFeatures()
          Expose features supported by the Resource Adapter.
 GenericObject getObject(java.lang.String objectType, java.lang.String objectId, java.util.List attrsToGet, java.util.Map options)
          Returns the requested objectId of the requested objectType from the resource
 Resource getResource()
           
 java.util.List getResourceAccounts(java.util.List attributes)
           
 WSUser getUser(WSUser user)
          Retrieves account information from the resource for the specified WSUser and returns a new WSUser based on the information from the resource.
 WSUser getUser(WSUser user, long timeout)
           
 boolean isSupported(java.lang.String feature)
           
 java.util.ArrayList listAllObjects(java.lang.String objectType, java.util.Map options, java.lang.String runAsUser, EncryptedData runAsPassword)
          This method will return a list of object names of the specified object type.
 java.util.ArrayList listAllObjects(java.lang.String objectType, java.util.Map options, java.lang.String runAsUser, EncryptedData runAsPassword, long timeout)
           
 java.util.List listObjects(java.util.Map options)
          Returns a list of all object types supported by the resource adapter that match based on the specified options.
 java.util.List listObjects(java.lang.String objectType, java.util.Map options)
           
 java.util.List listObjectsOfType(java.lang.String objectType, java.util.Map options)
          List objects of the specified object type that match the search criteria specified in @param options.
 boolean namesEqual(java.lang.String name1, java.lang.String name2)
           
 WavesetResult run(ResourceAction action)
          Runs a ResourceAction - The implementation almost always calls run(ResourceAction, Map) with a null Map.
 WavesetResult run(ResourceAction action, java.util.Map args)
          Runs a ResourceAction with additional args; could be null.
 WavesetResult scan(java.util.Map parameters)
           
 void setCache(ObjectCache cache)
           
 void setContext(LighthouseContext context)
           
 void setResource(Resource res)
           
 void setResourceObjectClassAttr(java.lang.String objectType, boolean primary)
          Set the object class attr value.
 boolean supportsAccountDisable()
          Indicates whether or not this resource supports account disable.
 boolean supportsActions()
           
 boolean supportsCaseInsensitiveAccountIds()
           
 boolean supportsContainerObjectTypes()
           
 boolean supportsExcludedAccounts()
           
 boolean supportsResourceAccount()
           
 boolean supportsScanning()
           
 WavesetResult testConfiguration()
          Test method.
 WavesetResult updateAccount(WSUser user)
           
 WavesetResult updateAccounts(WSUser[] users)
           
 WavesetResult updateObject(GenericObject object, java.util.Map options)
          Updates the specified objectId of type objectType using the list of attributes provided.
 WavesetResult updateResourceAccount(GenericObject account)
           
 

Field Detail

code_id

public static final java.lang.String code_id
See Also:
Constant Field Values

NEW_ACCOUNT_ID

public static final java.lang.String NEW_ACCOUNT_ID
When this appears as an account attribute, it means that the account should be renamed. Once the rename is successfuly, the adapter removes this attribute and chnages the ResourceInfo account id.

See Also:
Constant Field Values

DISABLE

public static final java.lang.String DISABLE
The name of an attribute used to pass disable requests. This is currently implemented by the provisioning engine, but eventually it should be handled by adapters.

See Also:
Constant Field Values

ENABLE

public static final java.lang.String ENABLE
The name of an attribute used to pass enable requests. This is currently implemented by the provisioning engine, but eventually it should be handled by adapters.

See Also:
Constant Field Values

UNLOCK

public static final java.lang.String UNLOCK
When this appears as an account attribute, it means that the resource is to unlock the user account.

See Also:
Constant Field Values

CHANGE_PASSWORD_LOCATION

public static final java.lang.String CHANGE_PASSWORD_LOCATION
When this appears as an account attribute, it means that the user should change the password at the location specified as the attr value. The format of this location is RA specific, e.g. for Active Directory, it is the DNS name of the domain controller on which to change the password.

See Also:
Constant Field Values

WS_USER_PASSWORD

public static final java.lang.String WS_USER_PASSWORD
When this appears as an account attribute, it means that the change password should be done as the user using the user's current resource password whose value is in this attribute.

See Also:
Constant Field Values

EXPIRE_PASSWORD

public static final java.lang.String EXPIRE_PASSWORD
When this appears as an account attribute, it means that the resource is to expire the password.

See Also:
Constant Field Values

RESET_PASSWORD

public static final java.lang.String RESET_PASSWORD
When this appears, it means that the resource is to reset the password.

See Also:
Constant Field Values

IGNORE_ATTR

public static final java.lang.String IGNORE_ATTR
Scema map attributes with this as their "right hand" value will not be sent to the resource - they are a way to communicate with the resource adapter. User for actions.

See Also:
Constant Field Values

GUID

public static final java.lang.String GUID
a GUID for a user resource account, populated by the adapter on create

See Also:
Constant Field Values

RA_DISPLAY_NAME_ATTR

public static final java.lang.String RA_DISPLAY_NAME_ATTR
The name of a resource account attribute whose value will be used when displaying the name of this account (e.g. samAccountName - where by default the full dn name would be displayed)

See Also:
Constant Field Values

RA_OBJECT_TYPE

public static final java.lang.String RA_OBJECT_TYPE
object Type

See Also:
Constant Field Values

RA_OBJECT_CLASS

public static final java.lang.String RA_OBJECT_CLASS
object Class ** Note ** This name is not set to "objectClass" in order to maintain backward compataibility with the ADSI Resource and gateway use of the string "Object Class" for this resource attribute

See Also:
Constant Field Values

RA_OBJECT_ID

public static final java.lang.String RA_OBJECT_ID
object Id

See Also:
Constant Field Values

RA_OBJECT_ATTRIBUTES

public static final java.lang.String RA_OBJECT_ATTRIBUTES
object attributes container

See Also:
Constant Field Values

RA_BASE_CTX

public static final java.lang.String RA_BASE_CTX
The base context used when searching for and resolving names in a hierarchical namespace, if searchContext not specified.

See Also:
Constant Field Values

RA_SEARCH_CONTEXT

public static final java.lang.String RA_SEARCH_CONTEXT
The context used when searching for and resolving names in a hierarchical namespace

See Also:
Constant Field Values

RA_SEARCH_ATTRIBUTE_NAMES

public static final java.lang.String RA_SEARCH_ATTRIBUTE_NAMES
The set of one or more attribue names used when searching for and resolving names in a hierarchical namespace within a specified search container

See Also:
Constant Field Values

RA_SEARCH_ATTRS_TO_GET

public static final java.lang.String RA_SEARCH_ATTRS_TO_GET
The set of one or more attribute names whose values should be returned in each object returned from a list / search request

See Also:
Constant Field Values

RA_SEARCH_SCOPE

public static final java.lang.String RA_SEARCH_SCOPE
The depth of the search in a hierarchical namespace (e.g. one level, all levels)

See Also:
Constant Field Values

RA_SEARCH_SCOPE_OBJECT

public static final java.lang.String RA_SEARCH_SCOPE_OBJECT
See Also:
Constant Field Values

RA_SEARCH_SCOPE_ONE_LEVEL

public static final java.lang.String RA_SEARCH_SCOPE_ONE_LEVEL
See Also:
Constant Field Values

RA_SEARCH_SCOPE_SUBTREE

public static final java.lang.String RA_SEARCH_SCOPE_SUBTREE
See Also:
Constant Field Values

RA_SEARCH_FILTER

public static final java.lang.String RA_SEARCH_FILTER
An optional search filter in LDAP filter format

See Also:
Constant Field Values

RA_SEARCH_TIME_LIMIT

public static final java.lang.String RA_SEARCH_TIME_LIMIT
The timelimit in milliseconds a search should not exceed

See Also:
Constant Field Values

RA_SEARCH_RUN_AS_USER

public static final java.lang.String RA_SEARCH_RUN_AS_USER
If specified, represent the user/password to authenticate to the resource with so all search operations will be performed running as the specified user and therefore scoped based on the user's access control on that resource.

See Also:
Constant Field Values

RA_SEARCH_RUN_AS_PASSWORD

public static final java.lang.String RA_SEARCH_RUN_AS_PASSWORD
See Also:
Constant Field Values

RA_REQUESTOR

public static final java.lang.String RA_REQUESTOR
The resource specific id of the user making the request. This can be used by the adapter to scope what is returned as well as what actions are allowed

See Also:
Constant Field Values

RA_NEW_OBJECT_NAME

public static final java.lang.String RA_NEW_OBJECT_NAME
When this appears as an object attribute, it means that the object should be renamed. Short name

See Also:
Constant Field Values

RA_NEW_OBJECT_ID

public static final java.lang.String RA_NEW_OBJECT_ID
When this appears as an object attribute, it means that the object should be renamed. Fully qualified name (e.g. dn)

See Also:
Constant Field Values

RA_OP_TYPE

public static final java.lang.String RA_OP_TYPE
Can be used to indicate a specific type of operation is being sent to the RA. For example, a valid value is "saveas" when the command is "create". This will allow the RA to have saveas specific processing within create (e.g. unix gids)

See Also:
Constant Field Values

RA_RENAME_OP

public static final java.lang.String RA_RENAME_OP
Rename operation.

See Also:
Constant Field Values

RA_SAVEAS_OP

public static final java.lang.String RA_SAVEAS_OP
Save As operation.

See Also:
Constant Field Values

SYSTEM_ATTRIBUTES

public static final java.lang.String[] SYSTEM_ATTRIBUTES
A collection of all builtin attributes. These are things that all adapters may recognize but won't be declared in the schema map. Recognition of any given attribute is not assured, you need to check the getFeatures map.


OP_LOCKED

public static final java.lang.String OP_LOCKED
See Also:
Constant Field Values

OP_EXPIRED

public static final java.lang.String OP_EXPIRED
See Also:
Constant Field Values

OP_NUMPWDAYS

public static final java.lang.String OP_NUMPWDAYS
See Also:
Constant Field Values

OP_PWNUMDAYS

public static final java.lang.String OP_PWNUMDAYS
See Also:
Constant Field Values

OP_NUMINACTIVEDAYS

public static final java.lang.String OP_NUMINACTIVEDAYS
See Also:
Constant Field Values

OP_DAYS_INACTIVE

public static final java.lang.String OP_DAYS_INACTIVE
See Also:
Constant Field Values

OP_DORMANT

public static final java.lang.String OP_DORMANT
See Also:
Constant Field Values

OP_NO_PASSWORD_SET

public static final java.lang.String OP_NO_PASSWORD_SET
See Also:
Constant Field Values

OP_INACTIVE

public static final java.lang.String OP_INACTIVE
See Also:
Constant Field Values

OP_NOOWNERSHIP

public static final java.lang.String OP_NOOWNERSHIP
See Also:
Constant Field Values

OP_NOPASSWORDREQ

public static final java.lang.String OP_NOPASSWORDREQ
See Also:
Constant Field Values

OP_EXPIREDPWD

public static final java.lang.String OP_EXPIREDPWD
See Also:
Constant Field Values

OP_DISABLED

public static final java.lang.String OP_DISABLED
See Also:
Constant Field Values
Method Detail

setResource

public void setResource(Resource res)

setCache

public void setCache(ObjectCache cache)

setContext

public void setContext(LighthouseContext context)

getResource

public Resource getResource()

createPrototypeResource

public Resource createPrototypeResource()
                                 throws WavesetException
Throws:
WavesetException

checkCreateAccount

public WavesetResult checkCreateAccount(WSUser user)
                                 throws WavesetException
Throws:
WavesetException

createAccount

public WavesetResult createAccount(WSUser user)
                            throws WavesetException
Throws:
WavesetException

createAccounts

public WavesetResult createAccounts(WSUser[] users)
                             throws WavesetException
Throws:
WavesetException

checkUpdateAccount

public WavesetResult checkUpdateAccount(WSUser user)
                                 throws WavesetException
Throws:
WavesetException

updateAccount

public WavesetResult updateAccount(WSUser user)
                            throws WavesetException
Throws:
WavesetException

updateAccounts

public WavesetResult updateAccounts(WSUser[] users)
                             throws WavesetException
Throws:
WavesetException

checkDeleteAccount

public WavesetResult checkDeleteAccount(WSUser user)
                                 throws WavesetException
Throws:
WavesetException

deleteAccount

public WavesetResult deleteAccount(WSUser user)
                            throws WavesetException
Throws:
WavesetException

deleteAccount

public WavesetResult deleteAccount(WSUser user,
                                   long timeout)
                            throws WavesetException,
                                   java.lang.InterruptedException
Delete the resource account specified by the input WSUser.

Parameters:
timeout - how many milliseconds to wait
Throws:
java.lang.InterruptedException - if the operation does not complete within the specified timeout.
WavesetException

deleteAccounts

public WavesetResult deleteAccounts(WSUser[] users)
                             throws WavesetException
Throws:
WavesetException

disableAccount

public WavesetResult disableAccount(WSUser user)
                             throws WavesetException
Throws:
WavesetException

disableAccounts

public WavesetResult disableAccounts(WSUser[] users)
                              throws WavesetException
Throws:
WavesetException

enableAccount

public WavesetResult enableAccount(WSUser user)
                            throws WavesetException
Throws:
WavesetException

enableAccounts

public WavesetResult enableAccounts(WSUser[] users)
                             throws WavesetException
Throws:
WavesetException

supportsAccountDisable

public boolean supportsAccountDisable()
Indicates whether or not this resource supports account disable. If it does not, the provisioning engine will attempt to simulate disable by generating random passwords. If we end up with more of these "can you do this" methods, we might want to generalize it into a more extensible way to describe features and levels of support.


getUser

public WSUser getUser(WSUser user)
               throws WavesetException
Retrieves account information from the resource for the specified WSUser and returns a new WSUser based on the information from the resource. Returns null if the account does not exist.

Throws:
WavesetException

getUser

public WSUser getUser(WSUser user,
                      long timeout)
               throws WavesetException,
                      java.lang.InterruptedException
Parameters:
timeout - how many milliseconds to wait
Returns:
a WSUser object representing the resource account (specified as the input WSUser). Returns null if the account does not exist.

Throws:
java.lang.InterruptedException - if the operation does not complete within the specified timeout.
WavesetException

authenticate

public WavesetResult authenticate(java.util.HashMap loginInfo)
                           throws WavesetException
Authenticates the user against the resource. If authentication is successful, the authenticated id will be returned. If more info is required to complete authentication the result will contain the required info

Throws:
WavesetException

getAccountAttributes

public WSAttributes getAccountAttributes(java.lang.String accountIdentity)
                                  throws WavesetException
This method is obsolete. ResourceAdapterBase provides a default implementation that throws a "not implemented" WavesetException.

Throws:
WavesetException

getAllAccounts

public java.util.List getAllAccounts()
                              throws WavesetException
Throws:
WavesetException

getAccountIterator

public AccountIterator getAccountIterator()
                                   throws WavesetException
Throws:
WavesetException

getAccountIterator

public AccountIterator getAccountIterator(long timeout)
                                   throws WavesetException,
                                          java.lang.InterruptedException
Parameters:
timeout - how many milliseconds to wait
Returns:
an account iterator.

Throws:
java.lang.InterruptedException - if the operation does not complete within the specified timeout.
WavesetException

getAccountIterator

public AccountIterator getAccountIterator(java.util.Map filterParams)
                                   throws WavesetException
Like getAccountIterator but takes a Map param. Supported entries are: "Search Filter String" : a String to put in the LDAP search filter. For standard object types (group, user), this will be appended in a string like (&(objectclass=class))

Throws:
WavesetException

createIdentity

public java.lang.String createIdentity(WSUser user)
                                throws WavesetException
Throws:
WavesetException

scan

public WavesetResult scan(java.util.Map parameters)
                   throws WavesetException
Throws:
WavesetException

supportsScanning

public boolean supportsScanning()
                         throws WavesetException
Throws:
WavesetException

supportsContainerObjectTypes

public boolean supportsContainerObjectTypes()
                                     throws WavesetException
Throws:
WavesetException

supportsResourceAccount

public boolean supportsResourceAccount()
                                throws WavesetException
Throws:
WavesetException

getBaseContextAttrName

public java.lang.String getBaseContextAttrName()
                                        throws WavesetException
Deprecated. As of 4.0 use getBaseContexts().

Needs to be overridden by subclass in order to support browsing and editing of resource objects

Returns:
the name, if any, of the attribute used by the resource as the base context or the context to which all operations is bound
Throws:
WavesetException

getBaseContexts

public java.util.List getBaseContexts()
                               throws WavesetException
Needs to be overridden by subclass in order to support browsing and editing of resource objects

Returns:
a list of the base context strings, if any. Return null if base contexts are not supported or defined.
Throws:
WavesetException

getBaseContextObject

public GenericObject getBaseContextObject(java.lang.String baseContext)
                                   throws WavesetException
Throws:
WavesetException

setResourceObjectClassAttr

public void setResourceObjectClassAttr(java.lang.String objectType,
                                       boolean primary)
Set the object class attr value.


getObject

public GenericObject getObject(java.lang.String objectType,
                               java.lang.String objectId,
                               java.util.List attrsToGet,
                               java.util.Map options)
                        throws WavesetException
Returns the requested objectId of the requested objectType from the resource

Parameters:
objectType - - a valid object type defined in the resource's section
objectId - - a valid fully qualified object identifier on this resource (e.g. "dn")
attrsToGet - - a list of attribute names supported by the specified objectType to be returned with the object
options - - not currently used since the objectId/objectType provide a unique identifier of the object being requested
Throws:
WavesetException

createObject

public WavesetResult createObject(GenericObject object,
                                  java.util.Map options)
                           throws WavesetException
Creates the specified objectId of type objectType using the list of attributes provided.

Parameters:
object - - a GenericObject containing the objectType, objectId, and list of attributes to be set on the new object
options - - several options can be specified which control the behavior of the search for referenced objects (e.g. group members) They include:
    "searchContext" - the value of this option determines within what context to perform search (ResourceAdapter.RA_SEARCH_CONTEXT). If no value, will assume search should be done from logical top.
  1. "searchScope" - specifies whether the search should be done on the current object, only within the context of the specified "searchContainer", or in all subcontext within the specified "searchContainer" (ResourceAdapter.RA_SEARCH_SCOPE). Valid values are "object", "oneLevel", or "subTree" indicates that the search should be performed on all sub containers within the specified "searchContainer".
  2. "searchTimeLimit" - the timelimit in milliseconds a search should not exceed (ResourceAdapter.RA_SEARCH_TIME_LIMIT).
  3. "searchAttributeNames" - a list of one or more attribute names used as the component of the tuple when searching for referenced objects (Resource_Adapter.RA_SEARCH_ATTRIBUTES).
    Throws:
    WavesetException

updateObject

public WavesetResult updateObject(GenericObject object,
                                  java.util.Map options)
                           throws WavesetException
Updates the specified objectId of type objectType using the list of attributes provided.

Parameters:
object - - a GenericObject containing the objectType, objectId, and list of new and changed attributes to be set on the object
options - - several options can be specified which control the behavior of the search for referenced objects (e.g. group members) They include:
    "searchContext" - the value of this option determines within what context to perform search (ResourceAdapter.RA_SEARCH_CONTEXT). If no value, will assume search should be done from logical top.
  1. "searchScope" - specifies whether the search should be done on the current object, only within the context of the specified "searchContainer", or in all subcontext within the specified "searchContainer" (ResourceAdapter.RA_SEARCH_SCOPE). Valid values are "object", "oneLevel", or "subTree" indicates that the search should be performed on all sub containers within the specified "searchContainer".
  2. "searchTimeLimit" - the timelimit in milliseconds a search should not exceed (ResourceAdapter.RA_SEARCH_TIME_LIMIT).
  3. "searchAttributeNames" - a list of one or more attribute names used as the component of the tuple when searching for referenced objects (Resource_Adapter.RA_SEARCH_ATTRIBUTES).
    Throws:
    WavesetException

deleteObject

public WavesetResult deleteObject(GenericObject object,
                                  java.util.Map options)
                           throws WavesetException
Deletes the requested objectId of the requested objectType from the resource

Parameters:
object -
options - - not currently used since the objectId/objectType provide a unique identifier of the object being deleted
Throws:
WavesetException

listObjectsOfType

public java.util.List listObjectsOfType(java.lang.String objectType,
                                        java.util.Map options)
                                 throws WavesetException
List objects of the specified object type that match the search criteria specified in @param options.

Throws:
WavesetException

listObjects

public java.util.List listObjects(java.util.Map options)
                           throws WavesetException
Returns a list of all object types supported by the resource adapter that match based on the specified options.

Throws:
WavesetException
See Also:
listObjects(String, Map).

listObjects

public java.util.List listObjects(java.lang.String objectType,
                                  java.util.Map options)
                           throws WavesetException
Parameters:
objectType - the name of an object class that is valid for the resource specified by the value of option "resId". If objectType is null, this method will list objects of the types specified in the resource's section.

options - control the behavior of the search. Supported options include:
searchContext
the target context to search. If not specified, this method will attempt to get a value from RA_BASE_CONTEXT. If this method cannot obtain a context value, this method will search from logical top.
Returns:
a list of objects matching the requested objectType and options

Must be overridden by each subclass in order to support browsing and editing of resource objects.

Throws:
WavesetException
See Also:
searchFilter
an LDAP search filter as specified in RFC 1558. String value consists of one or more object tuples
  
either and'ed or or'ed together. If not specified, this method will construct a search filter using the specified objectType.
,
searchScope
specifies how deeply to search. Valid values are:
"object"
search only on the current object
"oneLevel"
search directly within the specified "searchContext"
"subTree"
search every subcontext beneath the specified "searchContext"
,
"searchTimeLimit"
the timelimit in milliseconds} a search should not exceed.,
"searchAttrsToGet"
the list of objectType-specific attribute names to return for each listed object. @see #RA_SEARCH_ATTRS_TO_GET
"runAsUser"
user name as which to run this method. If not specified, defaults to resource proxy admin user.
"runAsPassword"
password of runAsUser. Required in order to authenticate with resource so that we can to execute the list request as the specified user.

What is the format? Is it encrypted and base-64-encoded, as returned by EncyptedData.toString()?


listAllObjects

public java.util.ArrayList listAllObjects(java.lang.String objectType,
                                          java.util.Map options,
                                          java.lang.String runAsUser,
                                          EncryptedData runAsPassword)
                                   throws WavesetException
This method will return a list of object names of the specified object type. If you need to be able to specify which attrs to return, use listObjects instead

Throws:
WavesetException

listAllObjects

public java.util.ArrayList listAllObjects(java.lang.String objectType,
                                          java.util.Map options,
                                          java.lang.String runAsUser,
                                          EncryptedData runAsPassword,
                                          long timeout)
                                   throws WavesetException,
                                          java.lang.InterruptedException
Parameters:
timeout - how many milliseconds to wait
Returns:
a list containing names of objects of the specified type. If you need to be able to specify which attrs to return, use listObjects instead.

Throws:
java.lang.InterruptedException - if the operation does not complete within the specified timeout.
WavesetException

getResourceAccounts

public java.util.List getResourceAccounts(java.util.List attributes)
                                   throws WavesetException
Parameters:
attributes - a list of attribute names whose values are to be returned with the account object.
Returns:
a list of objects which are used to identify accounts used to connect to the resource. The returned objects also contain the values of the requested attributes.

Throws:
WavesetException

updateResourceAccount

public WavesetResult updateResourceAccount(GenericObject account)
                                    throws WavesetException
Throws:
WavesetException

supportsActions

public boolean supportsActions()

supportsCaseInsensitiveAccountIds

public boolean supportsCaseInsensitiveAccountIds()
Returns:
true if the resource adapter supports case-insensitive account Ids; otherwise false. The default is return true, since most resources do not allow case-sensitive user names.

Any adapter for a resource with case-sensitive account ids should override this method to return false.


supportsExcludedAccounts

public boolean supportsExcludedAccounts()
Returns:
true if the resource adapter supports rules testing if specified accountIDs are to be excluded from certain listings; otherwise false. The default is return false.

Any adapter for a resource with support for exclusion of accounts should override this method to return true.


namesEqual

public boolean namesEqual(java.lang.String name1,
                          java.lang.String name2)
Returns:
true if name1 equals name2. The default implementation will do a simple string compare. However, for complex names (e.g. dn's ) associated with specific resource types (e.g. LDAP, NDS, AD, etc.) this method can be overridden to do necessary validation and normalization of both names prior to doing the string compare.

run

public WavesetResult run(ResourceAction action)
                  throws WavesetException
Runs a ResourceAction - The implementation almost always calls run(ResourceAction, Map) with a null Map.

Parameters:
action -
Returns:
The result of the action.
Throws:
WavesetException
See Also:
run(com.waveset.object.ResourceAction, java.util.Map)

run

public WavesetResult run(ResourceAction action,
                         java.util.Map args)
                  throws WavesetException
Runs a ResourceAction with additional args; could be null.

Parameters:
action - the action to run
args - passed to the action script; can be null
Returns:
a result with the results of the action execution.
Throws:
WavesetException

getFeatures

public GenericObject getFeatures()
Expose features supported by the Resource Adapter. Note: ActiveSync is considered a facet, not a feature.

Returns:
GenericObject containing Features, as both key and value, which are supported by this resource adapter.
See Also:
ResourceAdapter.Features

isSupported

public boolean isSupported(java.lang.String feature)

testConfiguration

public WavesetResult testConfiguration()
                                throws WavesetException
Test method. This method should check the configuration of the adapter, connecting to the host and validating that it has rights to do account create/update/delete actions.

Throws:
WavesetException