public class RouterAppManager extends ClientAppManagerImpl
Modifier and Type | Class and Description |
---|---|
class |
RouterAppManager.Shutdown |
_registered
Constructor and Description |
---|
RouterAppManager(RouterContext ctx) |
Modifier and Type | Method and Description |
---|---|
boolean |
addAndStart(ClientApp app,
String[] args) |
void |
addBubble(String svc,
String text)
Increment the count and set the text
|
int |
getBubbleCount(String svc)
Bubble count
|
String |
getBubbleText(String svc)
Bubble message, translated, not HTML escaped
|
ClientApp |
getClientApp(String className,
String[] args)
Get the first known ClientApp with this class name and exact arguments.
|
void |
notify(ClientApp app,
ClientAppState state,
String message,
Exception e)
Must be called on all state transitions except
from UNINITIALIZED to INITIALIZED.
|
boolean |
register(ClientApp app)
Register with the manager under the given name,
so that other clients may find it.
|
void |
renderStatusHTML(Writer out)
debug
|
void |
setBubble(String svc,
int count,
String text)
Update notifications for service
|
void |
shutdown() |
void |
unregister(ClientApp app)
Unregister with the manager.
|
getRegisteredApp
public RouterAppManager(RouterContext ctx)
public boolean addAndStart(ClientApp app, String[] args)
args
- the args that were used to instantiate the app, non-null, may be zero-lengthIllegalArgumentException
- if already addedpublic ClientApp getClientApp(String className, String[] args)
args
- non-null, may be zero-lengthpublic void notify(ClientApp app, ClientAppState state, String message, Exception e)
notify
in interface ClientAppManager
notify
in class ClientAppManagerImpl
app
- non-nullstate
- non-nullmessage
- may be nulle
- may be nullpublic boolean register(ClientApp app)
register
in interface ClientAppManager
register
in class ClientAppManagerImpl
app
- non-nullpublic void unregister(ClientApp app)
unregister
in interface ClientAppManager
unregister
in class ClientAppManagerImpl
app
- non-nullpublic int getBubbleCount(String svc)
getBubbleCount
in interface ClientAppManager
getBubbleCount
in class ClientAppManagerImpl
public String getBubbleText(String svc)
getBubbleText
in interface ClientAppManager
getBubbleText
in class ClientAppManagerImpl
public void setBubble(String svc, int count, String text)
setBubble
in interface ClientAppManager
setBubble
in class ClientAppManagerImpl
count
- 0 to cleartext
- translated, not HTML escaped, null if nonepublic void addBubble(String svc, String text)
addBubble
in interface ClientAppManager
addBubble
in class ClientAppManagerImpl
text
- translated, not HTML escaped, null if nonepublic void shutdown()
public void renderStatusHTML(Writer out) throws IOException
IOException