Class Session
java.lang.Object
com.ibm.jvm.dtfjview.Session
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Executes the supplied command.void
execute
(String line, PrintStream redirector) Execute a command line.void
Convenience method which instructs the session to search through all the available contexts and set the current one to the first one it finds with a non-corrupt DTFJ JavaRuntime in it.Get the manager which is managing this context within this session.The currently selected context against which commands will be executed.static ISession
getInstance
(String[] args) Factory method for creating new sessions.The instance which is managing all registered output channels.void
run()
void
setContext
(int id) Set the context within which subsequent commands will be executed.void
setContext
(ICombinedContext switchTo) Set the context within which subsequent commands will be executed.void
showContexts
(boolean shortFormat) Display the contexts which are present in the core file currently being analysed.
-
Field Details
-
LOGGER_PROPERTY
- See Also:
-
prompt
-
-
Method Details
-
getInstance
-
getOutputManager
Description copied from interface:ISession
The instance which is managing all registered output channels.- Specified by:
getOutputManager
in interfaceISession
- Returns:
- the manager
-
getCharset
-
getCurrentContext
Description copied from interface:ISession
The currently selected context against which commands will be executed.- Specified by:
getCurrentContext
in interfaceISession
- Returns:
- the current context, it may or may not have DDR interactive support
-
getContextManager
Description copied from interface:ISession
Get the manager which is managing this context within this session.- Specified by:
getContextManager
in interfaceISession
- Returns:
- the context manager
-
setContext
Description copied from interface:ISession
Set the context within which subsequent commands will be executed.- Specified by:
setContext
in interfaceISession
- Parameters:
id
- context ID- Throws:
CommandException
- thrown if an invalid context ID is specified
-
setContext
Description copied from interface:ISession
Set the context within which subsequent commands will be executed.- Specified by:
setContext
in interfaceISession
- Parameters:
switchTo
- the context to switch to- Throws:
CommandException
- thrown if the switch fails. The underlying reason will be in the logs.
-
showContexts
public void showContexts(boolean shortFormat) Description copied from interface:ISession
Display the contexts which are present in the core file currently being analysed.- Specified by:
showContexts
in interfaceISession
- Parameters:
shortFormat
- true for short format which just displays the first line of the java -version string
-
findAndSetContextWithJVM
public void findAndSetContextWithJVM()Description copied from interface:ISession
Convenience method which instructs the session to search through all the available contexts and set the current one to the first one it finds with a non-corrupt DTFJ JavaRuntime in it.- Specified by:
findAndSetContextWithJVM
in interfaceISession
-
run
public void run() -
execute
Execute a command line.- Parameters:
line
- The command line to be executed.redirector
- The PrintStream.
-
execute
-