org.apache.airavata.persistance.registry.jpa.resources
Class UserWorkflowResource

java.lang.Object
  extended by org.apache.airavata.persistance.registry.jpa.resources.AbstractResource
      extended by org.apache.airavata.persistance.registry.jpa.resources.UserWorkflowResource
All Implemented Interfaces:
Resource

public class UserWorkflowResource
extends AbstractResource


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.airavata.persistance.registry.jpa.resources.AbstractResource
AbstractResource.ApplicationDescriptorConstants, AbstractResource.ConfigurationConstants, AbstractResource.ExecutionErrorConstants, AbstractResource.ExperimentConstants, AbstractResource.ExperimentDataConstants, AbstractResource.GatewayConstants, AbstractResource.GatewayWorkerConstants, AbstractResource.GFacJobDataConstants, AbstractResource.GFacJobStatusConstants, AbstractResource.GramDataConstants, AbstractResource.HostDescriptorConstants, AbstractResource.NodeDataConstants, AbstractResource.ProjectConstants, AbstractResource.PublishedWorkflowConstants, AbstractResource.ServiceDescriptorConstants, AbstractResource.UserConstants, AbstractResource.UserWorkflowConstants, AbstractResource.WorkflowDataConstants
 
Field Summary
 
Fields inherited from class org.apache.airavata.persistance.registry.jpa.resources.AbstractResource
APPLICATION_DESCRIPTOR, CONFIGURATION, EXECUTION_ERROR, EXPERIMENT, EXPERIMENT_DATA, EXPERIMENT_METADATA, GATEWAY, GATEWAY_WORKER, GFAC_JOB_DATA, GFAC_JOB_STATUS, HOST_DESCRIPTOR, PROJECT, PUBLISHED_WORKFLOW, SERVICE_DESCRIPTOR, USER_WORKFLOW, USERS, WORKFLOW_DATA
 
Constructor Summary
UserWorkflowResource()
           
UserWorkflowResource(GatewayResource gateway, WorkerResource worker, String name)
           
 
Method Summary
 Resource create(ResourceType type)
          This method will create associate resource objects for the given resource type.
 List<Resource> get(ResourceType type)
          This method will list all the child resources for the given resource type
 Resource get(ResourceType type, Object name)
          This method will return the given child resource from the database
 String getContent()
           
 GatewayResource getGateway()
           
 Timestamp getLastUpdateDate()
           
 String getName()
           
 String getPath()
           
 WorkerResource getWorker()
           
 boolean isExists(ResourceType type, Object name)
          This method will check whether an entry from the given resource type and resource name exists in the database
 List<Resource> populate(Object[] keys)
           
 void remove(ResourceType type, Object name)
          This method will remove the given child resource from the database
 void save()
          This method will save the resource to the database.
 void setContent(String content)
           
 void setGateway(GatewayResource gateway)
           
 void setLastUpdateDate(Timestamp lastUpdateDate)
           
 void setName(String name)
           
 void setPath(String path)
           
 void setWorker(WorkerResource worker)
           
 
Methods inherited from class org.apache.airavata.persistance.registry.jpa.resources.AbstractResource
getResourceList
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserWorkflowResource

public UserWorkflowResource()

UserWorkflowResource

public UserWorkflowResource(GatewayResource gateway,
                            WorkerResource worker,
                            String name)
Method Detail

getName

public String getName()

setLastUpdateDate

public void setLastUpdateDate(Timestamp lastUpdateDate)

setContent

public void setContent(String content)

getLastUpdateDate

public Timestamp getLastUpdateDate()

getContent

public String getContent()

setName

public void setName(String name)

getPath

public String getPath()

setPath

public void setPath(String path)

create

public Resource create(ResourceType type)
Description copied from interface: Resource
This method will create associate resource objects for the given resource type.

Parameters:
type - child resource type
Returns:
associate child resource

remove

public void remove(ResourceType type,
                   Object name)
Description copied from interface: Resource
This method will remove the given child resource from the database

Parameters:
type - child resource type
name - child resource name

get

public Resource get(ResourceType type,
                    Object name)
Description copied from interface: Resource
This method will return the given child resource from the database

Parameters:
type - child resource type
name - child resource name
Returns:
associate child resource

populate

public List<Resource> populate(Object[] keys)
Parameters:
keys - should be in the order of gateway_name,user_name and user_workflow_name
Returns:
resource list

get

public List<Resource> get(ResourceType type)
Description copied from interface: Resource
This method will list all the child resources for the given resource type

Parameters:
type - child resource type
Returns:
list of child resources of the given child resource type

save

public void save()
Description copied from interface: Resource
This method will save the resource to the database.


isExists

public boolean isExists(ResourceType type,
                        Object name)
Description copied from interface: Resource
This method will check whether an entry from the given resource type and resource name exists in the database

Specified by:
isExists in interface Resource
Overrides:
isExists in class AbstractResource
Parameters:
type - child resource type
name - child resource name
Returns:
whether the entry exists in the database or not

getGateway

public GatewayResource getGateway()

setGateway

public void setGateway(GatewayResource gateway)

getWorker

public WorkerResource getWorker()

setWorker

public void setWorker(WorkerResource worker)


Copyright © 2011-2013 The Apache Software Foundation. All Rights Reserved.