net.eduvax.grant.core
Class TaskletContext

java.lang.Object
  extended by net.eduvax.grant.core.TaskletContext

public class TaskletContext
extends java.lang.Object

Tasklet execution context.


Field Summary
private  ExecRequest execRequest
          execute request
private  LocalNode node
          node resource for tasklet.
private  java.io.PrintStream out
          standard output
 
Constructor Summary
TaskletContext(ExecRequest request, LocalNode n)
          create new tasklet context
 
Method Summary
 ExecRequest getExecRequest()
           
 Node getNode()
           
 java.io.PrintStream getPrintStream()
           
 void sendEvent(java.lang.Object data)
          Fire runtime event.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

out

private java.io.PrintStream out
standard output


execRequest

private ExecRequest execRequest
execute request


node

private LocalNode node
node resource for tasklet.

Constructor Detail

TaskletContext

public TaskletContext(ExecRequest request,
                      LocalNode n)
create new tasklet context

Method Detail

getExecRequest

public ExecRequest getExecRequest()
Returns:
execute request

getPrintStream

public java.io.PrintStream getPrintStream()
Returns:
tasklet context standard output

getNode

public Node getNode()
Returns:
node that is running the tasklet.

sendEvent

public void sendEvent(java.lang.Object data)
Fire runtime event. Due to actual event transport communication, data must be serializable as a string (with toString() methods). Registered listener will recieve data as String class containing this serialization.

Parameters:
data - data to attach to the event.