org.eclipse.jetty.osgi.equinoxtools.console
Class WebConsoleSession
java.lang.Object
org.eclipse.osgi.framework.console.ConsoleSession
org.eclipse.jetty.osgi.equinoxtools.console.WebConsoleSession
- All Implemented Interfaces:
- org.osgi.framework.ServiceFactory
public class WebConsoleSession
- extends org.eclipse.osgi.framework.console.ConsoleSession
A simple console session for equinox.
- Author:
- hmalphettes
Methods inherited from class org.eclipse.osgi.framework.console.ConsoleSession |
close, getService, ungetService |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WebConsoleSession
public WebConsoleSession()
doClose
protected void doClose()
- Specified by:
doClose
in class org.eclipse.osgi.framework.console.ConsoleSession
getInput
public InputStream getInput()
- Specified by:
getInput
in class org.eclipse.osgi.framework.console.ConsoleSession
getOutput
public OutputStream getOutput()
- Specified by:
getOutput
in class org.eclipse.osgi.framework.console.ConsoleSession
getOutputAsWriter
public StringWriter getOutputAsWriter()
- For the output we are using a string writer in fact.
- Returns:
getSource
public PrintStream getSource()
- Returns:
- The print stream where commands can be written.
issueCommand
public void issueCommand(String cmd)
- Issue a command on the console.
- Parameters:
cmd
-
addOnFlushListener
public void addOnFlushListener(WebConsoleWriterOutputStream.OnFlushListener flushListener)
- Parameters:
flushListener
- Object that is called back when the outputstream is flushed.
removeOnFlushListener
public boolean removeOnFlushListener(WebConsoleWriterOutputStream.OnFlushListener flushListener)
- Parameters:
flushListener
- Object that is called back when the outputstream is flushed.
processCommand
public void processCommand(String cmd,
boolean wait)
- Process command comming from a web UI
- Parameters:
cmd
-
clearOutput
public void clearOutput()
getOnFlushListeners
public List<WebConsoleWriterOutputStream.OnFlushListener> getOnFlushListeners()
Copyright © 1995-2011 Mort Bay Consulting. All Rights Reserved.