org.crsh.term.console
Class ViewReader

java.lang.Object
  extended by org.crsh.term.console.ViewReader
All Implemented Interfaces:
Appendable

public abstract class ViewReader
extends Object
implements Appendable

Version:
$Revision$
Author:
Julien Viet

Constructor Summary
ViewReader()
           
 
Method Summary
abstract  ViewReader append(char c)
           
abstract  ViewReader append(CharSequence s)
           
abstract  ViewReader append(CharSequence csq, int start, int end)
           
abstract  int del()
          Delete the char under the cursor or return -1 if no char was deleted.
abstract  boolean moveLeft()
           
abstract  boolean moveRight()
           
abstract  CharSequence replace(CharSequence s)
          Replace all the characters before the cursor by the provided char sequence.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ViewReader

public ViewReader()
Method Detail

append

public abstract ViewReader append(char c)
                           throws IOException
Specified by:
append in interface Appendable
Throws:
IOException

append

public abstract ViewReader append(CharSequence s)
                           throws IOException
Specified by:
append in interface Appendable
Throws:
IOException

append

public abstract ViewReader append(CharSequence csq,
                                  int start,
                                  int end)
                           throws IOException
Specified by:
append in interface Appendable
Throws:
IOException

replace

public abstract CharSequence replace(CharSequence s)
                              throws IOException
Replace all the characters before the cursor by the provided char sequence.

Parameters:
s - the new char sequence
Returns:
the l
Throws:
IOException - any IOException

del

public abstract int del()
                 throws IOException
Delete the char under the cursor or return -1 if no char was deleted.

Returns:
the deleted char
Throws:
IOException - any IOException

moveRight

public abstract boolean moveRight()
                           throws IOException
Throws:
IOException

moveLeft

public abstract boolean moveLeft()
                          throws IOException
Throws:
IOException


Copyright © 2012 eXo Platform SAS. All Rights Reserved.