org.figure8.join.businessfacades.environment
Interface ResourceManager

All Known Implementing Classes:
DefaultResourceManager

public interface ResourceManager

This is a business interfaces providing methods for managing resources used by software project integration team. This manager also allows to manage mapping done between resources and physical environments.

Version:
$Revision: 1.4 $
Author:
Laurent Broudoux

Method Summary
 void closeEISMapping(EISMapping mapping)
          Closes the specified EISMapping.
 void closeResourceMapping(ResourceMapping mapping)
          Closes the specified ResourceMapping.
 EISMapping getEISMapping(long id)
          Retrieve an EISMapping using its unique identifier
 GatewayTrackingView getGatewayTrackingView(java.lang.String name, java.util.Date startDate, java.util.Date endDate)
          Get a configuration changes tracking view for a specified gateway on a specified time period (between start date and end date included).
 Machine getMachine(long id)
          Retrieve the Machine having the specified identifier
 java.util.List getMachines()
          Retrieve the available machines used by integration team.
 Resource getResource(long id)
          Retrieve the Resource hanving the specified identifier
 Resource getResource(java.lang.String name)
          Retrieve the Resource having the specified name
 ResourceMapping getResourceMapping(long id)
          Retrieve a ResourceMapping using its unique identifier
 java.util.List getResources(AbstractResourceType resourceType)
          Retrieve resources having the specified resource type
 java.util.List getResources(java.lang.String category)
          Retrieve resources corresponding to specified category
 ResourceType getResourceType(java.lang.String key)
          Retrieve the ResourceType having the specified key
 java.util.List getResourceTypes()
          Retrieve all defined resource types
 java.util.List getResourceTypes(java.lang.String category)
          Retrieve ResourceTypes corresponding to specified category
 ResourceVersion getResourceVersion(long id)
          Retrieve the ResourceVersion having this identifier
 ResourceVersion getResourceVersion(java.lang.String name)
          Retrieve the ResourceVersion having the specified name
 java.util.List getResourceVersions(VersionedResourceType resourceType)
          Retrieve the available resource versions for a resource type
 VersionedResource getVersionedResource(java.lang.String name, java.util.Date configDate)
          Get a view representing versioned resource configuration at a specified date
 VersionedResourceTrackingView getVersionedResourceTrackingView(java.lang.String name, java.util.Date startDate, java.util.Date endDate)
          Get a version updates tracking view for a specified versioned resource on a specified time period (between start date and end date included).
 void mapEISOnGateway(EIS eis, Gateway gateway)
          Create a new mapping of an EIS onto a gateway.
 void mapResourceOnEnvironment(AbstractResource resource, PhysicalEnvironment environment)
          Create a new mapping of an infrastructure resource onto a physical one.
 void saveMachine(Machine machine)
          Save a Machine within datastore (create or update)
 void saveResource(AbstractResource resource)
          Save a Resource within datastore (create or update).
 void saveResourceType(AbstractResourceType type)
          Save a ResourceType within datastore (create or update).
 void saveResourceVersion(ResourceVersion version)
          Save a RsourceVersion within datastore (create or update)
 void updateResource(VersionedResource resource, ResourceVersion version)
          Update a versioned resource using a resource version
 

Method Detail

saveResourceType

void saveResourceType(AbstractResourceType type)
                      throws DuplicateEntityException
Save a ResourceType within datastore (create or update). Only types that are EntityObjects (AbstractResourceTypes) can be saved at that time.

Parameters:
type - The ResourceType to save
Throws:
DuplicateEntityException - if a ResourceType with same key already exists

getResourceTypes

java.util.List getResourceTypes(java.lang.String category)
Retrieve ResourceTypes corresponding to specified category

Parameters:
category - The category resource types whould belong to
Returns:
A list of org.figure8.join.businessobjects.environment.ResourceType of this category

getResourceTypes

java.util.List getResourceTypes()
Retrieve all defined resource types

Returns:
A list of org.figure8.join.businessobjects.environment.ResourceType

getResourceType

ResourceType getResourceType(java.lang.String key)
Retrieve the ResourceType having the specified key

Parameters:
key - The unique key identifier of the ResourceType
Returns:
The ResourceType having this key or null if no type has the specified key

saveResource

void saveResource(AbstractResource resource)
                  throws DuplicateEntityException
Save a Resource within datastore (create or update). Only resource that are EntityObjects (AbstractResources) can be saved at that time.

Parameters:
resource - The Resource to save
Throws:
DuplicateEntityException - if a resource wiht same key already exists

getResources

java.util.List getResources(AbstractResourceType resourceType)
Retrieve resources having the specified resource type

Parameters:
resourceType - The type resources should belong to
Returns:
A list of org.figure8.join.businessobjects.environment.Resource of this type

getResources

java.util.List getResources(java.lang.String category)
Retrieve resources corresponding to specified category

Parameters:
category - The category resources should belong to
Returns:
A list of org.figure8.join.businessobjects.environment.Resource of this category

getResource

Resource getResource(java.lang.String name)
Retrieve the Resource having the specified name

Parameters:
name - The name of the Resource to retrieve
Returns:
The corresponding Resource or null if no Resource has the specified name

getResource

Resource getResource(long id)
Retrieve the Resource hanving the specified identifier

Parameters:
id - The identifier of Resource to retrieve
Returns:
The corresponding Resource or null if no Resource has this identifier

getGatewayTrackingView

GatewayTrackingView getGatewayTrackingView(java.lang.String name,
                                           java.util.Date startDate,
                                           java.util.Date endDate)
Get a configuration changes tracking view for a specified gateway on a specified time period (between start date and end date included).

Parameters:
name - The name of gateway to retrieve a tracking view for
startDate - The date to start the configuration changes tracking
endDate - The date to end the configuration changes tracking
Returns:
A GatewayTrackingView for requested tracking period

getVersionedResource

VersionedResource getVersionedResource(java.lang.String name,
                                       java.util.Date configDate)
Get a view representing versioned resource configuration at a specified date

Parameters:
name - The name of resource to retrieve configuration for
configDate - The date to get resource configuration
Returns:
A VersionedResource for requested date

getVersionedResourceTrackingView

VersionedResourceTrackingView getVersionedResourceTrackingView(java.lang.String name,
                                                               java.util.Date startDate,
                                                               java.util.Date endDate)
Get a version updates tracking view for a specified versioned resource on a specified time period (between start date and end date included).

Parameters:
name - The name of resource to retrieve a tracking view for
startDate - The date to start the resource version updates tracking
endDate - The date to end the resource version updates tracking
Returns:
A VersionedResourceTrackingView for requested tracking period

saveResourceVersion

void saveResourceVersion(ResourceVersion version)
                         throws DuplicateEntityException
Save a RsourceVersion within datastore (create or update)

Parameters:
version - The resource version to save
Throws:
DuplicateEntityException - is a resource with same name already exists

getResourceVersions

java.util.List getResourceVersions(VersionedResourceType resourceType)
Retrieve the available resource versions for a resource type

Parameters:
resourceType - The VersionedResourceType to get versions for
Returns:
A list of org.figure8.join.businessobjects.environment.ResourceVersion

getResourceVersion

ResourceVersion getResourceVersion(java.lang.String name)
Retrieve the ResourceVersion having the specified name

Parameters:
name - The name of ResourceVersion to retrieve
Returns:
The corresponding ResourceVersion or null if no one has this name

getResourceVersion

ResourceVersion getResourceVersion(long id)
Retrieve the ResourceVersion having this identifier

Parameters:
id - The unique identifier of ResourceVersion to retrieve
Returns:
The corresponding ResourceVersion or null if no one has this identifier

updateResource

void updateResource(VersionedResource resource,
                    ResourceVersion version)
Update a versioned resource using a resource version

Parameters:
resource - The VersionedResource to update
version - The ResourceVersion to use for update

saveMachine

void saveMachine(Machine machine)
                 throws DuplicateEntityException
Save a Machine within datastore (create or update)

Parameters:
machine - The machine to save
Throws:
DuplicateEntityException - if a machine with same name already exists

getMachines

java.util.List getMachines()
Retrieve the available machines used by integration team.

Returns:
A list of org.figure8.join.businessobjects.environment.Machine

getMachine

Machine getMachine(long id)
Retrieve the Machine having the specified identifier

Parameters:
id - The identifier ot Machine to retrieve
Returns:
The corresponding Machine or null if no Machine has this identifier

getResourceMapping

ResourceMapping getResourceMapping(long id)
Retrieve a ResourceMapping using its unique identifier

Parameters:
id - The unique identifier of mapping to retrieve
Returns:
The corresponding ResourceMapping or null if no one match

mapResourceOnEnvironment

void mapResourceOnEnvironment(AbstractResource resource,
                              PhysicalEnvironment environment)
Create a new mapping of an infrastructure resource onto a physical one. This closes the previously existing active mapping on environment for a resource of same type (if any).

Parameters:
resource - The infrastructure resource to map onto environemnt
environment - The physical environment to be mapped with resource

closeResourceMapping

void closeResourceMapping(ResourceMapping mapping)
Closes the specified ResourceMapping. This involves deactivating it and removing it from active mapping list within its related physical environments.

Parameters:
mapping - The ResourceMapping to close

getEISMapping

EISMapping getEISMapping(long id)
Retrieve an EISMapping using its unique identifier

Parameters:
id - The unique identifier of mapping to retrieve
Returns:
The corresponding EISMapping or null if no one match

mapEISOnGateway

void mapEISOnGateway(EIS eis,
                     Gateway gateway)
Create a new mapping of an EIS onto a gateway. This closes the previously existing active mapping on gateway for the EIS of same type (if any).

Parameters:
eis - The EIS to map onto gateway
gateway - The gateway to be mapped with EIS

closeEISMapping

void closeEISMapping(EISMapping mapping)
Closes the specified EISMapping. This involves deactivating it and removing is from active mapping list within its related gateway.

Parameters:
mapping - The EISMapping to close


Copyright © 2005-2008 Join. All Rights Reserved.