org.objectweb.proactive.core.descriptor.data
Class MainDefinition

java.lang.Object
  extended byorg.objectweb.proactive.core.descriptor.data.MainDefinition
All Implemented Interfaces:
java.io.Serializable

public class MainDefinition
extends java.lang.Object
implements java.io.Serializable

A MainDefinition is an internal representation of XML mainDefinition element.

Since:
ProActive 3.0
Version:
1.0, 2005/09/20
Author:
ProActive Team
See Also:
VirtualNode, VirtualMachine, Serialized Form

Constructor Summary
MainDefinition()
           
MainDefinition(java.lang.String mainClass)
           
MainDefinition(java.lang.String mainClass, java.util.List parameters, java.util.List virtualNodeList)
           
 
Method Summary
 void activateMain()
          activates all nodes of the list virtualNodeList
 void addParameter(java.lang.String parameter)
          add a parameter to the list of parameters, at the last position
 void addVirtualNode(VirtualNode virtualNode)
          add a virtual node to the list of virtal nodes
 java.lang.String getMainClass()
          return the fully qualified name of the class containing the main method
 java.lang.String[] getParameters()
          return a table of String containing all the parameters to apply to the main method
 VirtualNode getVirtualNode(int i)
          return the i-th virtual node of the list
 java.util.List getVirtualNodeList()
          return the list of virtual nodes
 VirtualNode[] getVirtualNodes()
          return a table of virtual nodes
 void setMainClass(java.lang.String mainClass)
          set the main class attribute
 void setParameters(java.util.List parameters)
          set the list of parameters
 void setVirtualNodeList(java.util.List virtualNodeList)
          set the list of virtual nodes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MainDefinition

public MainDefinition(java.lang.String mainClass,
                      java.util.List parameters,
                      java.util.List virtualNodeList)

MainDefinition

public MainDefinition(java.lang.String mainClass)

MainDefinition

public MainDefinition()
Method Detail

activateMain

public void activateMain()
activates all nodes of the list virtualNodeList


setVirtualNodeList

public void setVirtualNodeList(java.util.List virtualNodeList)
set the list of virtual nodes

Parameters:
virtualNodeList - new list

setMainClass

public void setMainClass(java.lang.String mainClass)
set the main class attribute

Parameters:
mainClass - fully qualified name of the class containing a main method

setParameters

public void setParameters(java.util.List parameters)
set the list of parameters

Parameters:
parameters - list of String

getVirtualNodeList

public java.util.List getVirtualNodeList()
return the list of virtual nodes

Returns:
list of virtual nodes

getVirtualNodes

public VirtualNode[] getVirtualNodes()
return a table of virtual nodes

Returns:
a table of virtual nodes

addVirtualNode

public void addVirtualNode(VirtualNode virtualNode)
add a virtual node to the list of virtal nodes

Parameters:
virtualNode - virtual node to add

getVirtualNode

public VirtualNode getVirtualNode(int i)
return the i-th virtual node of the list

Parameters:
i - index of the virtual node to get
Returns:
the i-th virtual node of the list

getMainClass

public java.lang.String getMainClass()
return the fully qualified name of the class containing the main method

Returns:
fully qualified name of the class containing the main method

getParameters

public java.lang.String[] getParameters()
return a table of String containing all the parameters to apply to the main method

Returns:
a table of String containing all the parameters to apply to the main method

addParameter

public void addParameter(java.lang.String parameter)
add a parameter to the list of parameters, at the last position

Parameters:
parameter - parameter to add to the list of parameters


Copyright 2001-2005 INRIA All Rights Reserved.