org.crsh.command
Class PipeCommand<E>

java.lang.Object
  extended by org.crsh.command.PipeCommand<E>
Type Parameters:
E - the element generic type
All Implemented Interfaces:
Flushable, Pipe<E>
Direct Known Subclasses:
PipeCommandProxy, PipeLine.PipeProxy

public abstract class PipeCommand<E>
extends Object
implements Pipe<E>

A pipe command.


Field Summary
private  boolean piped
          .
 
Constructor Summary
PipeCommand()
           
 
Method Summary
 void close()
          Close pipe.
 void flush()
          Flush pipe.
 boolean isPiped()
           
 void open()
          Open pipe.
 void provide(E element)
          Extends the throw clause of the Pipe.provide(Object) method.
 void setPiped(boolean piped)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

piped

private boolean piped
.

Constructor Detail

PipeCommand

public PipeCommand()
Method Detail

isPiped

public final boolean isPiped()

setPiped

public final void setPiped(boolean piped)

open

public void open()
          throws ScriptException
Open pipe.

Throws:
ScriptException

provide

public void provide(E element)
             throws ScriptException,
                    IOException
Extends the throw clause of the Pipe.provide(Object) method.

Specified by:
provide in interface Pipe<E>
Parameters:
element - the provided element
Throws:
ScriptException - any script exception
IOException - any io exception

flush

public void flush()
           throws ScriptException,
                  IOException
Flush pipe.

Specified by:
flush in interface Flushable
Throws:
ScriptException - any script exception
IOException - any io exception

close

public void close()
           throws ScriptException
Close pipe.

Throws:
ScriptException - any script exception


Copyright © 2012 eXo Platform SAS. All Rights Reserved.