edu.sdsc.inca.agent.access
Class GlobusOutputListener

java.lang.Object
  extended by edu.sdsc.inca.agent.access.GlobusOutputListener
All Implemented Interfaces:
org.globus.io.gass.server.JobOutputListener

public class GlobusOutputListener
extends java.lang.Object
implements org.globus.io.gass.server.JobOutputListener

A subclass of JobOutputListener that can be used store output being sent to a GASS server. The output is stored in a string therefore, this class should not be used for any large output.

Author:
Shava Smallen <ssmallen@sdsc.edu>

Constructor Summary
GlobusOutputListener()
           
 
Method Summary
 java.lang.String getOutput()
          Return the output that has been collected on this GASS stream.
 void outputChanged(java.lang.String output)
          Called whenever the GASS server receives input for the stream this listener was registered for.
 void outputClosed()
          Called whenever the stream for the GASS server is closed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GlobusOutputListener

public GlobusOutputListener()
Method Detail

outputChanged

public void outputChanged(java.lang.String output)
Called whenever the GASS server receives input for the stream this listener was registered for. We add the output to our internal string buffer.

Specified by:
outputChanged in interface org.globus.io.gass.server.JobOutputListener
Parameters:
output -

outputClosed

public void outputClosed()
Called whenever the stream for the GASS server is closed. We do nothing since were using a string to store the output (and it doesn't need to be closed).

Specified by:
outputClosed in interface org.globus.io.gass.server.JobOutputListener

getOutput

public java.lang.String getOutput()
Return the output that has been collected on this GASS stream.

Returns:
The output received by the GASS server for the registered stream.