|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mycore.frontend.servlets.MCRWebCLIContainer
class MCRWebCLIContainer
Is a wrapper class around command execution.
Commands will be queued and executed in a
seperate thread. All logging events in that thread are grabbed and can be
retrieved by the getLogs method.
| Field Summary | |
|---|---|
(package private) Future<Boolean> |
curFuture
|
| Constructor Summary | |
|---|---|
MCRWebCLIContainer(List<MCRCommand> knownCommands,
HttpSession session)
Will instantiate this container with a list of supported commands. |
|
| Method Summary | |
|---|---|
void |
addCommand(String cmd)
Adds this cmd to the current command queue. |
LinkedList<String> |
getCommandQueue()
Gets the current command queue. |
net.sf.json.JSONObject |
getLogs()
Returns all logs that were grabbed in the command execution thread. |
boolean |
isRunning()
Returns the status of the command execution thread. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
Future<Boolean> curFuture
| Constructor Detail |
|---|
public MCRWebCLIContainer(List<MCRCommand> knownCommands,
HttpSession session)
knownCommands - commands that are supported by the web gui.session - the current HttpSession of the usere using the gui.| Method Detail |
|---|
public void addCommand(String cmd)
cmd to the current command queue.
The thread executing the commands will be started automatically if the
queue was previously empty.
cmd - a valid String representation of a known MCRCommandpublic LinkedList<String> getCommandQueue()
public boolean isRunning()
public net.sf.json.JSONObject getLogs()
logLevel,message,exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||