org.isam.exehda.services.primos
Class ExecutorImpl

java.lang.Object
  |
  +--org.isam.exehda.services.AbstractService
        |
        +--org.isam.exehda.services.primos.ExecutorImpl
All Implemented Interfaces:
Executor, Service

public class ExecutorImpl
extends AbstractService
implements Executor


Nested Class Summary
 
Nested classes inherited from class org.isam.exehda.services.Executor
Executor.MarshaledOX, Executor.Migrable, Executor.SchedulingHeuristic
 
Field Summary
 
Fields inherited from interface org.isam.exehda.services.Executor
SERVICE_NAME
 
Constructor Summary
ExecutorImpl()
           
 
Method Summary
 void activateObject(Executor.MarshaledOX oxState)
          Describe activateObject method here.
 ObjectSeed.ObjectHandle createObject(ApplicationId app, java.lang.Class cls, java.lang.Object[] params, ObjectSeed.Activator a, java.lang.Object hint)
          Describe createObject method here.
 ApplicationId currentApplication()
          Describe currentApplication method here.
 void deactivateObject(ObjectId ox, Executor.MarshaledOX oxState)
          Describe deactivateObject method here.
 void exitApplication()
          Describe exitApplication method here.
 void moveObject(ObjectId ox, java.lang.Object placementHint)
          Describe moveObject method here.
 void runAction(ApplicationId aid, java.lang.Runnable action)
          Describe runAction method here.
 void setHeuristic(Executor.SchedulingHeuristic h)
          This method is deprecated, avoid using it in new code.
 void start()
           
 void startApplication(org.isam.util.xml.XmlElement launchDescriptor)
          Describe startApplication method here.
 void stop()
           
 
Methods inherited from class org.isam.exehda.services.AbstractService
log, log, log, log, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExecutorImpl

public ExecutorImpl()
Method Detail

start

public void start()
           throws java.lang.ClassNotFoundException,
                  java.lang.InstantiationException,
                  java.lang.IllegalAccessException,
                  java.net.UnknownHostException
Specified by:
start in interface Service
java.lang.ClassNotFoundException
java.lang.InstantiationException
java.lang.IllegalAccessException
java.net.UnknownHostException

stop

public void stop()
          throws java.lang.Exception
Specified by:
stop in interface Service
java.lang.Exception

startApplication

public void startApplication(org.isam.util.xml.XmlElement launchDescriptor)
Description copied from interface: Executor
Describe startApplication method here. TODO: change parameter type to String

Specified by:
startApplication in interface Executor
Parameters:
launchDescriptor - a XmlDocument value

createObject

public ObjectSeed.ObjectHandle createObject(ApplicationId app,
                                            java.lang.Class cls,
                                            java.lang.Object[] params,
                                            ObjectSeed.Activator a,
                                            java.lang.Object hint)
Description copied from interface: Executor
Describe createObject method here.

Specified by:
createObject in interface Executor
Parameters:
cls - a Class value
params - an Object[] value
a - an Activator value
hint - an Object value
Returns:
an ObjectId value

moveObject

public void moveObject(ObjectId ox,
                       java.lang.Object placementHint)
Description copied from interface: Executor
Describe moveObject method here.

Specified by:
moveObject in interface Executor
Parameters:
ox - an ObjectId value
placementHint - an Object value

deactivateObject

public void deactivateObject(ObjectId ox,
                             Executor.MarshaledOX oxState)
Description copied from interface: Executor
Describe deactivateObject method here.

Specified by:
deactivateObject in interface Executor
Parameters:
ox - an ObjectId value
oxState - a MarshaledOX value

activateObject

public void activateObject(Executor.MarshaledOX oxState)
Description copied from interface: Executor
Describe activateObject method here.

Specified by:
activateObject in interface Executor
Parameters:
oxState - a MarshaledOX value

exitApplication

public void exitApplication()
Description copied from interface: Executor
Describe exitApplication method here.

Specified by:
exitApplication in interface Executor

setHeuristic

public void setHeuristic(Executor.SchedulingHeuristic h)
Description copied from interface: Executor
This method is deprecated, avoid using it in new code. Sets the per-application scheduling heuristic.

Specified by:
setHeuristic in interface Executor
Parameters:
h - a SchedulingHeuristic value

currentApplication

public ApplicationId currentApplication()
Description copied from interface: Executor
Describe currentApplication method here.

Specified by:
currentApplication in interface Executor
Returns:
an ApplicationId value

runAction

public void runAction(ApplicationId aid,
                      java.lang.Runnable action)
Description copied from interface: Executor
Describe runAction method here.

Specified by:
runAction in interface Executor
Parameters:
aid - an ApplicationId value
action - a Runnable value