org.objectweb.easybeans.deployable.impl
Class AbsDeployable<T>

java.lang.Object
  extended by org.objectweb.easybeans.deployable.impl.AbsDeployable<T>
Type Parameters:
T - the type of the deployable.
All Implemented Interfaces:
EZBDeployable<T>
Direct Known Subclasses:
CARDeployableImpl, EARDeployableImpl, EJB21DeployableImpl, EJB3DeployableImpl, LibDeployableImpl, RARDeployableImpl, UnknownDeployableImpl, WARDeployableImpl

public abstract class AbsDeployable<T>
extends java.lang.Object
implements EZBDeployable<T>

Defines the common stuff for the deployable objects.

Author:
Florent Benoit

Field Summary
private  EZBArchive archive
          Archive used for this deployable.
private  T originalDeployable
          Original Deployable (not unpacked).
private  T unpackedDeployable
          Unpacked version of this deployable.
 
Constructor Summary
AbsDeployable(EZBArchive archive)
          Defines and create a deployable for the given archive.
 
Method Summary
 EZBArchive getArchive()
          Gets the Archive of this deployable object.
 T getOriginalDeployable()
          If the Deployable has been unpacked, return the initial deployable.
 T getUnpackedDeployable()
          If the Deployable has been unpacked, return the unpacked deployable.
 void setOriginalDeployable(T originalDeployable)
          If the EAR has been unpacked, return the initial archive.
 void setUnpackedDeployable(T unpackedDeployable)
          If the Deployable has been unpacked, sets the unpacked deployable.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

archive

private EZBArchive archive
Archive used for this deployable.


originalDeployable

private T originalDeployable
Original Deployable (not unpacked).


unpackedDeployable

private T unpackedDeployable
Unpacked version of this deployable.

Constructor Detail

AbsDeployable

public AbsDeployable(EZBArchive archive)
Defines and create a deployable for the given archive.

Parameters:
archive - the given archive.
Method Detail

getArchive

public EZBArchive getArchive()
Gets the Archive of this deployable object.

Specified by:
getArchive in interface EZBDeployable<T>
Returns:
the archive for this deployable.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
Returns:
String representation.

getOriginalDeployable

public T getOriginalDeployable()
If the Deployable has been unpacked, return the initial deployable.

Specified by:
getOriginalDeployable in interface EZBDeployable<T>
Returns:
the deployable before it is unpacked.

setOriginalDeployable

public void setOriginalDeployable(T originalDeployable)
If the EAR has been unpacked, return the initial archive.

Parameters:
originalDeployable - the deployable before it is unpacked.

getUnpackedDeployable

public T getUnpackedDeployable()
If the Deployable has been unpacked, return the unpacked deployable.

Specified by:
getUnpackedDeployable in interface EZBDeployable<T>
Returns:
the unpacked deployable associated to this deployable.

setUnpackedDeployable

public void setUnpackedDeployable(T unpackedDeployable)
If the Deployable has been unpacked, sets the unpacked deployable.

Specified by:
setUnpackedDeployable in interface EZBDeployable<T>
Parameters:
unpackedDeployable - the unpacked deployable associated to this deployable.