RUNNING, START_PENDING, STARTING, STATUS_NAMES, STOP_PENDING, STOPPED
Constructor and Description |
---|
VMTaskFiber(String taskName,
String entryClassName,
String[] entryArguments,
URL[] searchPaths)
Constructs a new Virtual Macine Task Fiber.
|
Modifier and Type | Method and Description |
---|---|
String |
getName()
Returns the name for the virtual machine task.
|
int |
getStatus()
Returns the current status of the fiber.
|
void |
run()
This method invokes the entry method on the main class.
|
void |
start()
Starts the current fiber running.
|
void |
stop()
Stops the current fiber.
|
public VMTaskFiber(String taskName, String entryClassName, String[] entryArguments, URL[] searchPaths) throws ClassNotFoundException, NoSuchMethodException
taskName
- The name of the taskentryClassName
- The name of the entry class.entryArguments
- The String array passed to main.searchPaths
- The URL's used to locate resources and classes.ClassNotFoundException
- Thrown if the entry class is not found.NoSuchMethodException
- Thrown if the main
is not found on the entry
class.URLClassLoader
public void run()
public void stop()
STOP_PENDING
. When the main thread exits then the service
is considered stopped!public int getStatus()
Copyright © 2015. All Rights Reserved.