This section provides details about the methods available with the Resource Web service. This programming interface presumes you’re using Java code generated by the WSSDK toolkit. The interface will be different if you’re using another Web Service toolkit.
This section provides reference information for each method associated with the IRemoteResource interface.
Makes a grant resource request and returns a resource request correlation ID.
Syntax: Here is the method signature:
public String requestResourceGrant(String resourceTarget, String requester, String userTarget, String reasonForRequest, ResourceRequestParam[] requestParams, String correlationId) throws NrfServiceException, RemoteException;
The parameters are described below:
resourceTarget specifies the target resource DN.
requester supplies an identifier for the remote client application making the request to grant the resource.
userTarget specifies the DN for the being granted the resource.
reasonForRequest provides a reason for the request.
requestParams provides the parameter values for the request.
correlationId specifies a resource assignment request correlation ID; if the parameter is null, a correlation ID is generated.
The requester parameter is a client-supplied identifier for the agent making the request. For example, an identifier such as IRemote-MyApplicationName might be used to identify a request from MyApplicationName. The requestParams are the dynamic parameter values required by the resource to make a request. If no values are required, the parameter value can be null or an empty array. The correlationId allows a client to group request for the purpose of checking the staus. If the parameter value is null, the service generates a unique correlation id. The correlation id is returned to the caller.
Makes a revoke resource request and returns a resource request correlation ID.
The revoke invocation behavior mirrors the behavior for a grant opeation, except that a revoke request for the resource is posted on the server.
Syntax: Here is the method signature:
public String requestResourceRevoke(String resourceTarget, String requester, String userTarget, String reasonForRequest, ResourceRequestParam[] requestParams, String correlationId) throws NrfServiceException, RemoteException;
The parameters are described below:
resourceTarget specifies the target resource DN.
requester supplies an identifier for the remote client application making the request to revoke the resource.
userTarget specifies the DN for the being granted the resource.
reasonForRequest provides a reason for the request.
requestParams provides the parameter values for the request.
correlationId specifies a resource assignment request correlation ID; if the parameter is null, a correlation ID is generated.
Returns the resource assignments for the current user.
Syntax: Here is the method signature:
ResourceAssignment[] getResourceAssignmentsForCurrentUser() throws com.novell.idm.nrf.soap.ws.resource.NrfServiceException, java.rmi.RemoteException;
Returns the resource assignments for a particular user.
Syntax: Here is the method signature:
ResourceAssignment[] getResourceAssignmentsForUser(java.lang.String userDn) throws com.novell.idm.nrf.soap.ws.resource.NrfServiceException, java.rmi.RemoteException;
The parameters are described below:
userDn DN of the target user
Returns the resource assignments for a particular resource.
Syntax: Here is the method signature:
ResourceAssignment[] getAssignmentsForResource(java.lang.String resourceDn) throws com.novell.idm.nrf.soap.ws.resource.NrfServiceException, java.rmi.RemoteException;
The parameters are described below:
resourceDN DN of the target resource
Returns all resource request status items for a given correlation ID.
Syntax: Here is the method signature:
public ResourceAssignmentRequestStatus[] getResourceRequestStatusByCorrelationId (String correlationId, String locale) throws NrfServiceException, RemoteException;
The parameters are described below:
correlationId specifies a resource assignment request correlation ID.
locale supplies an iso639 language code to format localized string values; if the parameter is null, the language defaults to the servlet request locale.
This method returns all resource request status instances for the specified correlationId parameter value. For more information on the ResourceAssignmentRequestStatus class, see Section 23.2.3, ResourceAssignmentRequestStatus.
Returns all resource request status items for the authenticated user.
Syntax: Here is the method signature:
public ResourceAssignmentRequestStatus[] getResourceRequestStatusForCurrentUser(String locale) throws NrfServiceException, RemoteException;
The parameters are described below:
locale supplies an iso639 language code to format localized string values; if the parameter is null, the language defaults to the servlet request locale.
This method returns all resource request status instances for the specified correlationId parameter value. For more information on the ResourceAssignmentRequestStatus class, see Section 23.2.3, ResourceAssignmentRequestStatus.
Returns all resource assignment request status items for a particular user identity.
Syntax: Here is the method signature:
public ResourceAssignmentRequestStatus[] getResourceRequestStatusByIdentity(String identity, String locale) throws NrfServiceException, RemoteException;
The parameters are described below:
identity specifies the DN for a user.
locale supplies an iso639 language code to format localized string values; if the parameter is null, the language defaults to the servlet request locale.
This method returns all resource request status instances for the specified correlationId parameter value. For more information on the ResourceAssignmentRequestStatus class, see Section 23.2.3, ResourceAssignmentRequestStatus.
Returns a list of code map values for a specified code map.
Syntax: Here is the method signature:
public CodeMapValue[] getCodeMapValues(String codeMapKey, String locale) throws NrfServiceException, RemoteException;
The parameters are described below:
codeMapKey specifies the code map key to retrieve values from
locale supplies an iso639 language code to format localized string values; if the parameter is null, the language defaults to the servlet request locale.
Returns a resource object.
Syntax: Here is the method signature:
public Resource getResource(String dn, String locale) throws NrfServiceException, RemoteException;
The parameters are described below:
dn specifies the DN of the resource you want to retrieve.
locale supplies an iso639 language code to format localized string values; if the parameter is null, the language defaults to the servlet request locale.
Creates a new resource according to the specified parameters, and returns a DN of the created resource.
A correlation ID is generated automatically for this method that uses this format:
UserApp#RemoteResourceRequest#xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
The correlation ID is used for auditing.
Syntax: Here is the method signature:
public String createResource(Resource resource) throws NrfServiceException, RemoteException;
The parameters are described below:
resource specifies the resource object to create.
Creates a new resource, with a correlation ID that you provide. The correlation ID is used for auditing to link a set of related resources. This method creates the resource according to the specified parameters, and returns a DN of the created resource.
Syntax: Here is the method signature:
public String createResourceAid(Resource resource, String correlationId) throws NrfServiceException, RemoteException;
Deletes a specified resource from the Resource Catalog. Returns the DN for the deleted resource as a confirmation.
A correlation ID is generated automatically for this method that uses this format:
UserApp#RemoteResourceRequest#xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
The correlation ID is used for auditing.
Syntax: Here is the method signature:
public DNString removeResource(DNString resourceDn) throws NrfServiceException, RemoteException;
The parameters are described below:
resourceDn specifies the DN of the resource to delete.
Deletes a specified resource from the Resource Catalog, with a correlation ID that you provide. The correlation ID is used for auditing to link a set of related resources. This method returns the DN for the deleted resource as a confirmation.
Syntax: Here is the method signature:
public DNString removeResourceAid(DNString resourceDn, String correlation Id) throws NrfServiceException, RemoteException;
Modifies a resource definition. This method does not perform a localized string modification update. To update the localized names or descriptions for a resource, you need to use the setResourceLocalizedStrings method.
A correlation ID is generated automatically for this method that uses this format:
UserApp#RemoteResourceRequest#xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
Syntax: Here is the method signature:
public Resource modifyResource(Resource resource) throws NrfServiceException, RemoteException;
The parameters are described below:
resource specifies the resource object to modify.
Modifies a resource definition, with a correlation ID that you provide. The correlation ID is used for auditing to link a set of related resources. This method does not perform a localized string modification update. To update the localized names or descriptions for a resource, you need to use the setResourceLocalizedStrings method.
Syntax: Here is the method signature:
public Resource modifyResourceAid(Resource resource, String correlationId) throws NrfServiceException, RemoteException;
Gets the localized strings for a resource, such as the names and descriptions. The type parameter lets you specify whether the names or descriptions should be retrieved.
Syntax: Here is the method syntax:
public LocalizedValue[] getResourceLocalizedStrings(String resourceDn, int type)throws NrfServiceException, RemoteException;
The parameters are described below:
resourceDn specifies the DN of the resource for which you want to get the localized strings.
type specifies the type of localized strings you want to retrieve. A type value of 1 retrieves a list of names for the resource, whereas a type value of 2 retrieves a list of descriptions.
Sets the localized strings for a resource, such as the names and descriptions.
A correlation ID is generated automatically for this method that uses this format:
UserApp#RemoteResourceRequest#xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
Syntax: Here is the method signature:
public LocalizedValue[] setResourceLocalizedStrings(String resourceDn, LocalizedValue[] locStrings, int type) throws NrfServiceException, RemoteException;
The parameters are described below:
resourceDn specifies the DN of the resource for which you want to set the localized strings.
locStrings provides an array of localized strings you want to define.
type specifies the type of localized strings you want to retrieve. A type value of 1 retrieves a list of names for the resource, whereas a type value of 2 retrieves a list of descriptions.
Sets the localized strings for a resource, such as the names and descriptions, with a correlation ID that you provide. The correlation ID is used for auditing to link a set of related resources.
Syntax: Here is the method signature:
public LocalizedValue[] setResourceLocalizedStringsAid(String resourceDn, LocalizedValue[] locStrings, int type, String correlationId) throws NrfServiceException, RemoteException;
Returns a list of ResourceInfo instances given a list of category keys.
Syntax: Here is the method signature:
public ResourceInfo[] getResourcessInfoByCategory(CategoryKey[] resourceCategoryKeys) throws NrfServiceException, RemoteException;
The parameters are described below:
resourceCategoryKeys specifies the list of resource category keys to retrieve resource information objects for.
Finds all Resource objects based on the search criteria specified in the given Resource object.
Syntax: Here is the method signature:
public Resource[] findResourceByExampleWithOperator(Resource searchCriteria, boolean useAndForMultiValueSearch) throws NrfServiceException, RemoteException;
The parameters are described below:
searchCriteria specifies Query by Example (QBE) search criteria within a Resource object.
useAndForMultiValueSearch determines whether AND or OR will be used for multi-value search expressions. If you specify a value of true, AND will be used for multi-value searches; if you specify a value of false, OR will be used.
Returns a list of ResourceInfo instances given a list of resource DNs.
Syntax: Here is the method signature:
public ResourceInfo[] getResourcessInfo(DNString[] resDns) throws NrfServiceException, RemoteException;
The parameters are described below:
resDns provides a list of resource DNs for which you want to retrieve resource information objects.
Supporting class that holds the name and value for a resource request parameter value.
The ResourceRequestParam class has two constructors.
Syntax 1: Here is the syntax for a constructor that takes no parameters:
public ResourceRequestParam() { }
Syntax 2: Here is the syntax for a constructor that takes two String parameters:
public ResourceRequestParam(String name, String value) { m_name = name; m_value = value; }
Sets a parameter name.
Syntax: Here is the method signature:
public void setName(String name)
Returns a parameter name.
Syntax: Here is the method signature:
public String getName()
Sets the value of a parameter.
Syntax: Here is the method signature:
public void setValue(String value)
Returns the value of a parameter.
Syntax: Here is the method signature:
public String getValue()
Supporting class that holds a resource request status item. The interface includes methods for getting and setting various request status properties. However, you will not need to call the methods for setting property values, since you are using this class to retrieve information about the request status. After calling the requestResourceGrant() or the requestResourceRevoke() methods, you can use the get methods to get the properties for each status object returned in the ResourceAssignmentRequestStatus array.
Sets the entity key.
Syntax: Here is the method signature:
public void setEntityKey(String entityKey)
Gets the entity key.
Syntax: Here is the method signature:
public String getEntityKey()
Sets the reason for the role assignment.
Syntax: Here is the method signature:
public void setReason(String reason)
Gets the reason for the role assignment.
Syntax: Here is the method signature:
public String getReason()
Sets the status value for the request.
Syntax: Here is the method signature:
public void setStatusValue(int value)
Sets the status description for the request.
Syntax: Here is the method signature:
public void setStatusDescription(String description)
Gets the status value for the request.
Syntax: Here is the method signature:
public int getStatusValue()
Gets the localized description for the request.
Syntax: Here is the method signature:
public String getStatusDescription()
Sets the correlation ID.
Syntax: Here is the method signature:
public void setCorrelationId(String correlationId)
Gets the correlation ID.
Syntax: Here is the method signature:
public String getCorrelationId()
Sets the requester DN.
Syntax: Here is the method signature:
public void setRequester(String requester)
Gets the requester DN.
Syntax: Here is the method signature:
public String getRequester()
Sets the request date.
Syntax: Here is the method signature:
public void setRequestDate(Date requestDate)
Gets the request date.
Syntax: Here is the method signature:
public Date getRequestDate()
Sets the source resource DN.
Syntax: Here is the method signature:
public void setSource(String source)
Gets the source resource DN.
Syntax: Here is the method signature:
public String getSource()
Sets the DN for the target identity.
Syntax: Here is the method signature:
public void setTarget(String target)
Gets the DN for the target identity.
Syntax: Here is the method signature:
public String getTarget()
Sets the dynamic request parameters.
Syntax: Here is the method signature:
public void setRequestParams(ResourceRequestParam[] params)
Gets the dynamic request parameters.
Syntax: Here is the method signature:
public ResourceRequestParam[] getRequestParams()