org.gridlab.gat.resources
Class SoftwareResourceDescription

java.lang.Object
  extended by org.gridlab.gat.resources.ResourceDescription
      extended by org.gridlab.gat.resources.SoftwareResourceDescription
All Implemented Interfaces:
Serializable

public class SoftwareResourceDescription
extends ResourceDescription

An instance of this class is a description of a software resource, which may be required by a hardware or software component. It does not describe the application itself, the SoftwareDescription is used for that.

To clarify this concept, let us give various examples. A software library is described by a SoftwareResourceDescription; a helper application is described by a SoftwareResourceDescription; a plugin is described by a SoftwareResourceDescription... However, a piece of hardware is not described by a SoftwareResourceDescription.

Software is generally useless without hardware. For example, a software driver without the appropriate Disk drive is all but useless. Similarly, software often depends upon other software. For example, having a Photoshop without any plugins is not of much use. Hence, in describing a software component one needs to also describe the software and hardware that this software component requires. This is reflected in the fact that a SoftwareResourceDescription contains in addition to a "parent" description of a software component a list of HardwareResourceDescriptions, each element of which describes a hardware component upon which the parent software component depends, and a list of SoftwareResourceDescriptions, each element of which describes a software component upon which the parent software component depends. Hence, the entire structure is recursive.

To construct an instance of a SoftwareResourceDescription one requires three quantities:

The GAT-API defines a minimum set of supported name/value pairs which can be included in the map used to construct a SoftwareResourceDescription instance. This minimum set of name/value pairs MUST be supported by any implementation of the GAT-API. This minimum set of supported name/values is given in the table

Minimum set of supported name/value pairs
Name Type Description
os.name String The os name as returned from uname -s
os.type String The os type as returned from uname -p
os.version String The os version as returned from uname -v
os.release String The os release as returned from uname -r

See Also:
Serialized Form

Field Summary
static String OS_NAME
          The os name as returned from uname -s.
static String OS_RELEASE
          The os release as returned from uname -r.
static String OS_TYPE
          The os type as returned from uname -p.
static String OS_VERSION
          The os version as returned from uname -v.
 
Constructor Summary
SoftwareResourceDescription()
          Constructs a SoftwareResourceDescription associated without attributes and dependencies.
SoftwareResourceDescription(Map<String,Object> attributes)
          Constructs a SoftwareResourceDescription associated with the passed attributes.
SoftwareResourceDescription(Map<String,Object> attributes, List<ResourceDescription> resourceDescriptions)
          Constructs a SoftwareResourceDescription associated with the passed objects.
 
Method Summary
 
Methods inherited from class org.gridlab.gat.resources.ResourceDescription
addResourceAttribute, addResourceDescription, equals, getDescription, getResourceAttribute, hashCode, removeResourceAttribute, removeResourceDescription, setDescription, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

OS_NAME

public static final String OS_NAME
The os name as returned from uname -s.

See Also:
Constant Field Values

OS_TYPE

public static final String OS_TYPE
The os type as returned from uname -p.

See Also:
Constant Field Values

OS_VERSION

public static final String OS_VERSION
The os version as returned from uname -v.

See Also:
Constant Field Values

OS_RELEASE

public static final String OS_RELEASE
The os release as returned from uname -r.

See Also:
Constant Field Values
Constructor Detail

SoftwareResourceDescription

public SoftwareResourceDescription()
Constructs a SoftwareResourceDescription associated without attributes and dependencies.


SoftwareResourceDescription

public SoftwareResourceDescription(Map<String,Object> attributes)
Constructs a SoftwareResourceDescription associated with the passed attributes. There are no further dependencies

Parameters:
attributes - A Map, which describes the attributes of this resource

SoftwareResourceDescription

public SoftwareResourceDescription(Map<String,Object> attributes,
                                   List<ResourceDescription> resourceDescriptions)
Constructs a SoftwareResourceDescription associated with the passed objects.

Parameters:
attributes - A Map, which describes the attributes of this resource
resourceDescriptions - A List, which is a list of ResourceDescriptions each of which describes a software component upon which this software component depends.