Class StorageType
- java.lang.Object
-
- edu.isi.pegasus.planner.catalog.site.classes.SiteData
-
- edu.isi.pegasus.planner.catalog.site.classes.AbstractSiteData
-
- edu.isi.pegasus.planner.catalog.site.classes.StorageType
-
- All Implemented Interfaces:
java.lang.Cloneable
- Direct Known Subclasses:
HeadNodeScratch,HeadNodeStorage,WorkerNodeScratch,WorkerNodeStorage
public class StorageType extends AbstractSiteData
An Abstract Data class to describe the filesystem layout on a site, both shared and local on a site/node- Version:
- $Revision$
- Author:
- Karan Vahi
-
-
Field Summary
Fields Modifier and Type Field Description protected LocalDirectorymLocalDirectoryThe local directory on the node.protected SharedDirectorymSharedDirectoryThe shared directory on the node.
-
Constructor Summary
Constructors Constructor Description StorageType()The default constructorStorageType(LocalDirectory local, SharedDirectory shared)The overloaded constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(SiteDataVisitor visitor)Accept method for the SiteData classes that accepts a visitorjava.lang.Objectclone()Returns the clone of the object.private voidcomplain(Directory.TYPE type)Throws a Runtime ExceptionLocalDirectorygetLocalDirectory()Returns the local directory.SharedDirectorygetSharedDirectory()Returns the shared directory.voidsetLocalDirectory(Directory local)Sets the local directory.voidsetLocalDirectory(LocalDirectory local)Sets the local directory.voidsetSharedDirectory(Directory shared)Sets the shared directory.voidsetSharedDirectory(SharedDirectory shared)Sets the shared directory.voidtoXML(java.io.Writer writer, java.lang.String indent)Writes out the xml description of the object.-
Methods inherited from class edu.isi.pegasus.planner.catalog.site.classes.AbstractSiteData
toString, toXML, writeAttribute
-
-
-
-
Field Detail
-
mLocalDirectory
protected LocalDirectory mLocalDirectory
The local directory on the node.
-
mSharedDirectory
protected SharedDirectory mSharedDirectory
The shared directory on the node.
-
-
Constructor Detail
-
StorageType
public StorageType()
The default constructor
-
StorageType
public StorageType(LocalDirectory local, SharedDirectory shared)
The overloaded constructor.- Parameters:
local- the local directory on the node.shared- the shared directory on the node.
-
-
Method Detail
-
setLocalDirectory
public void setLocalDirectory(LocalDirectory local)
Sets the local directory.- Parameters:
local- the local directory.
-
setLocalDirectory
public void setLocalDirectory(Directory local)
Sets the local directory.- Parameters:
local- the local directory.
-
getLocalDirectory
public LocalDirectory getLocalDirectory()
Returns the local directory.- Returns:
- the local directory.
-
setSharedDirectory
public void setSharedDirectory(SharedDirectory shared)
Sets the shared directory.- Parameters:
shared- the shared directory.
-
setSharedDirectory
public void setSharedDirectory(Directory shared)
Sets the shared directory.- Parameters:
shared- the shared directory.
-
getSharedDirectory
public SharedDirectory getSharedDirectory()
Returns the shared directory.- Returns:
- the shared directory.
-
clone
public java.lang.Object clone()
Returns the clone of the object.- Overrides:
clonein classAbstractSiteData- Returns:
- the clone
-
complain
private void complain(Directory.TYPE type)
Throws a Runtime Exception- Parameters:
Directory- .TYPE the directory type
-
toXML
public void toXML(java.io.Writer writer, java.lang.String indent) throws java.io.IOExceptionDescription copied from class:AbstractSiteDataWrites out the xml description of the object.- Specified by:
toXMLin classAbstractSiteData- Parameters:
writer- is a Writer opened and ready for writing. This can also be a StringWriter for efficient output.indent- the indent to be used.- Throws:
java.io.IOException- if something fishy happens to the stream.
-
accept
public void accept(SiteDataVisitor visitor) throws java.io.IOException
Description copied from class:AbstractSiteDataAccept method for the SiteData classes that accepts a visitor- Specified by:
acceptin classAbstractSiteData- Parameters:
visitor- the visitor to be used- Throws:
java.io.IOException- if something fishy happens to the stream.
-
-