org.figure8.join.businessobjects.environment.persistence
Class HibernateDeploymentDao

java.lang.Object
  extended by org.springframework.orm.hibernate.support.HibernateDaoSupport
      extended by org.figure8.join.core.persistence.HibernateObjectDao
          extended by org.figure8.join.businessobjects.environment.persistence.HibernateDeploymentDao
All Implemented Interfaces:
DeploymentDao, ObjectDao, org.springframework.beans.factory.InitializingBean

public class HibernateDeploymentDao
extends HibernateObjectDao
implements DeploymentDao

Implementation of DeploymentDao using Hibernate ORM system.

Version:
$Revision: 1.2 $
Author:
Laurent Broudoux

Field Summary
 
Fields inherited from class org.springframework.orm.hibernate.support.HibernateDaoSupport
logger
 
Constructor Summary
HibernateDeploymentDao()
          Creates a new instance of HibernateDeploymentDao
 
Method Summary
 Deployment getActiveDeploymentForMapping(EnvironmentMapping mapping)
          Retrieve the currently active deployment done using an EnvironmentMapping
 Deployment getDeployment(long id)
          Retrieve a deployment specified by its identifier
 java.util.List getDeploymentsByLogicalEnvironment(LogicalEnvironment logicalEnv)
          Retrieve all the deployments done for a specified logical environment
 java.util.List getDeploymentsByPhysicalEnvironment(PhysicalEnvironment physicalEnv)
          Retrieve all the deployments done onto a specified physical environment
 java.util.List getDeploymentsHavingStatus(java.util.List status, boolean includeNull)
          Get all the deployments having one of the specified status
 java.lang.Class getPersistentClass()
          Get the persistent class associated to this Dao.
 java.util.List getPreparingDeployments()
          Get all the deployments being prepared at time of invocation
 java.util.List getRealizingDeployments()
          Get all the deployments being realized at time of invocation
 
Methods inherited from class org.figure8.join.core.persistence.HibernateObjectDao
findAll, findAllSorted, findNamedQuery, findNamedQuery, findNamedQuery, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findSingleObject, getById, initialize, initializeAssociation, isInitialized, refresh, remove, replicate, save
 
Methods inherited from class org.springframework.orm.hibernate.support.HibernateDaoSupport
afterPropertiesSet, closeSessionIfNecessary, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, initDao, setHibernateTemplate, setSessionFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.figure8.join.core.persistence.ObjectDao
findAll, findAllSorted, initialize, initializeAssociation, isInitialized, refresh, remove, replicate, save
 

Constructor Detail

HibernateDeploymentDao

public HibernateDeploymentDao()
Creates a new instance of HibernateDeploymentDao

Method Detail

getDeployment

public Deployment getDeployment(long id)
Retrieve a deployment specified by its identifier

Specified by:
getDeployment in interface DeploymentDao
Parameters:
id - The unique identifier of deployment to retrieve
Returns:
The deployment corresponding to id or null if no deployment has this is

getActiveDeploymentForMapping

public Deployment getActiveDeploymentForMapping(EnvironmentMapping mapping)
Retrieve the currently active deployment done using an EnvironmentMapping

Specified by:
getActiveDeploymentForMapping in interface DeploymentDao
Parameters:
mapping - The mapping to get last active deployment for
Returns:
The active deployment corresponding to mapping, or null if none.

getRealizingDeployments

public java.util.List getRealizingDeployments()
Get all the deployments being realized at time of invocation

Specified by:
getRealizingDeployments in interface DeploymentDao
Returns:
A list of Deployments

getPreparingDeployments

public java.util.List getPreparingDeployments()
Get all the deployments being prepared at time of invocation

Specified by:
getPreparingDeployments in interface DeploymentDao
Returns:
A list of Deployments

getDeploymentsHavingStatus

public java.util.List getDeploymentsHavingStatus(java.util.List status,
                                                 boolean includeNull)
Get all the deployments having one of the specified status

Specified by:
getDeploymentsHavingStatus in interface DeploymentDao
Parameters:
status - A list of specified status
includeNull - Flag telling if deployment with no status should be included
Returns:
A list of Deployments

getDeploymentsByLogicalEnvironment

public java.util.List getDeploymentsByLogicalEnvironment(LogicalEnvironment logicalEnv)
Retrieve all the deployments done for a specified logical environment

Specified by:
getDeploymentsByLogicalEnvironment in interface DeploymentDao
Parameters:
logicalEnv - The logical environment to get deployments for
Returns:
A list of Deployments done for logical environment

getDeploymentsByPhysicalEnvironment

public java.util.List getDeploymentsByPhysicalEnvironment(PhysicalEnvironment physicalEnv)
Retrieve all the deployments done onto a specified physical environment

Specified by:
getDeploymentsByPhysicalEnvironment in interface DeploymentDao
Parameters:
physicalEnv - The physical environment to get deployments for
Returns:
A list of Deployments done onto this physical environemnt

getPersistentClass

public java.lang.Class getPersistentClass()
Description copied from interface: ObjectDao
Get the persistent class associated to this Dao.

Specified by:
getPersistentClass in interface ObjectDao
Returns:
The org.figure8.join.businessobjects.environment.Deployment class


Copyright © 2005-2008 Join. All Rights Reserved.