uk.org.ogsadai.service.wsrf.resource
Class DataServiceResourceWrapper
java.lang.Object
|
+--uk.org.ogsadai.service.wsrf.resource.DataServiceResourceWrapper
- All Implemented Interfaces:
- org.globus.wsrf.Resource, org.globus.wsrf.ResourceIdentifier, org.globus.wsrf.ResourceLifetime, org.globus.wsrf.ResourceProperties
- public class DataServiceResourceWrapper
- extends java.lang.Object
- implements org.globus.wsrf.Resource, org.globus.wsrf.ResourceLifetime, org.globus.wsrf.ResourceIdentifier, org.globus.wsrf.ResourceProperties
A wrapper for exposing uk.org.ogsadai.service.resource.DataServiceResource
objects as Globus Toolkit-compliant WS-Resources.
Each object has an associated ResourcePropertySet
. This has a name {https://ogsadai.org.uk/namespaces/2005/10/service/wsrf/dataservice}DataServiceResourcePropertiesSet
(held in constant uk.org.ogsadai.service.wsrf.WSRFConstants.RP_SET
).
- Author:
- The OGSA-DAI Team.
- See Also:
Resource
, ResourceIdentifier
, ResourceLifetime
, ResourceProperties
, DataServiceResource
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
COPYRIGHT_NOTICE
private static final java.lang.String COPYRIGHT_NOTICE
-
Copyright statement
- See Also:
- Constant Field Values
LOG
private static DAILogger LOG
-
Logger object for logging in this class
mDataServiceResource
private DataServiceResource mDataServiceResource
-
Wrapped
DataServiceResource
mTerminationTime
private java.util.Calendar mTerminationTime
-
Resource termination time
mPropertySet
private org.globus.wsrf.ResourcePropertySet mPropertySet
-
Resource properties in Globus Toolkit-compliant format
DataServiceResourceWrapper
public DataServiceResourceWrapper(java.lang.Object id,
DataResourceAccessor dataResourceAccessor,
ActivitiesConfig activitiesConfig,
SessionComponentFactory sessionComponentFactory,
SecurityContextProvider securityContextProvider,
ConcurrencySettings concurrency,
AccessAuthorizer authority)
throws ResourceCreationException
-
Create a new data service resource wrapped within this wrapper. This includes building a WSRF-compliant
ResourcePropertySet
to expose the properties of the data service resource.
- Parameters:
id
- ID of the data service resource - used to construct the ResourceKey
dataResourceAccessor
- The data resource accessor that gives access to any underlying data resource.
activitiesConfig
- Configuration details regarding the activity that can be used with the resource.
sessionComponentFactory
- A factory to create the session components required by a data service resource.
securityContextProvider
- Object that will provide security information for use when accessing resource property values.
concurrency
- Default concurrency settings for the resource.
authority
- Authorizes access to the activities supported by this data service resource.
- Throws:
ResourceCreationException
- if the data service resource cannot be created for some reason.
java.lang.IllegalArgumentException
- if securityContextProvider
is null
.
- See Also:
DataServiceResource
buildResourcePropertySet
private void buildResourcePropertySet(SecurityContextProvider securityContextProvider)
-
Wrap the data service resource properties in Globus-compliant wrapper classes and add them to a
org.globus.wsrf.ResourcePropertySet
.
-
-
- Parameters:
securityContextProvider
- Object that will provide security information for use when accessing resource property values. Each property wrapper will be given a reference to this provider.
setTerminationTime
public void setTerminationTime(java.util.Calendar time)
-
- Specified by:
setTerminationTime
in interface org.globus.wsrf.ResourceLifetime
-
getTerminationTime
public java.util.Calendar getTerminationTime()
-
- Specified by:
getTerminationTime
in interface org.globus.wsrf.ResourceLifetime
-
getCurrentTime
public java.util.Calendar getCurrentTime()
-
- Specified by:
getCurrentTime
in interface org.globus.wsrf.ResourceLifetime
-
getID
public java.lang.Object getID()
-
- Specified by:
getID
in interface org.globus.wsrf.ResourceIdentifier
-
getResourcePropertySet
public org.globus.wsrf.ResourcePropertySet getResourcePropertySet()
-
- Specified by:
getResourcePropertySet
in interface org.globus.wsrf.ResourceProperties
-
getDataServiceResource
public DataServiceResource getDataServiceResource()
-
Return the wrapped data service resource.
-
-
- Returns:
- the data service resource.