public class MockServiceDaemon extends Object implements MockServiceDaemonMBean
PAUSE_PENDING, PAUSED, RESUME_PENDING
RUNNING, START_PENDING, STARTING, STATUS_NAMES, STOP_PENDING, STOPPED
Constructor and Description |
---|
MockServiceDaemon(String name) |
Modifier and Type | Method and Description |
---|---|
String |
getName()
This method is used to return the name of the
Fiber . |
boolean |
getStartCalled() |
int |
getStatus()
This method is used to get the current status of the
Fiber . |
String |
getStatusText()
status
|
void |
pause()
This method is used to suspend a currently running
Fiber . |
void |
resume()
This method is used to resume a suspeneded
Fiber . |
void |
start()
This method is used to start the initialization process of the
Fiber , which should eventually transition to a
RUNNING status. |
void |
stop()
This method is used to stop a currently running
Fiber . |
public MockServiceDaemon(String name)
public String getStatusText()
ServiceDaemon
status
getStatusText
in interface ServiceDaemon
String
object.public void pause()
PausableFiber
Fiber
.
When invoked the Fiber
will begin the transition to
a PAUSED
status after changing its internal state, if
applicable.pause
in interface PausableFiber
public void resume()
PausableFiber
Fiber
. If the
thread is already running then this method should have no effect on the
current Fiber
.resume
in interface PausableFiber
public String getName()
Fiber
Fiber
. The
name of the instance is defined by the implementor, but it should be
realitively unique when possible.public int getStatus()
Fiber
Fiber
.
The status of the fiber should be one of the predefined constants of the
Fiber
interface, or from one of the derived interfaces.public void start()
Fiber
Fiber
, which should eventually transition to a
RUNNING
status.public boolean getStartCalled()
Copyright © 2021. All rights reserved.