Geant4-11
|
#include <G4UIterminal.hh>
Public Types | |
using | Transformer = std::function< G4bool(G4String &)> |
Public Member Functions | |
void | AddCerrTransformer (const Transformer &t) |
void | AddCerrTransformer (Transformer &&t) |
void | AddCoutTransformer (const Transformer &t) |
void | AddCoutTransformer (Transformer &&t) |
G4UIterminal (G4VUIshell *aShell=0, G4bool qsig=true) | |
G4int | GetLastReturnCode () const |
virtual void | PauseSessionStart (const G4String &msg) |
virtual G4int | ReceiveG4cerr (const G4String &cerrString) |
G4int | ReceiveG4cerr_ (const G4String &msg) |
virtual G4int | ReceiveG4cout (const G4String &coutString) |
G4int | ReceiveG4cout_ (const G4String &msg) |
virtual void | ResetTransformers () |
virtual G4UIsession * | SessionStart () |
void | SetPrompt (const G4String &prompt) |
~G4UIterminal () | |
Static Public Member Functions | |
static G4int | InSession () |
Protected Member Functions | |
void | ApplyShellCommand (const G4String &, G4bool &, G4bool &) |
G4bool | ChangeDirectory (const char *newDir) |
void | ChangeDirectoryCommand (const G4String &) |
G4String | Complete (const G4String &) |
G4UIcommand * | FindCommand (const char *commandName) const |
G4UIcommandTree * | FindDirectory (const char *dirName) const |
G4String | FindMatchingPath (G4UIcommandTree *, const G4String &) |
G4String | GetCurrentWorkingDirectory () const |
void | ListDirectory (const G4String &) const |
G4String | ModifyToFullPathCommand (const char *aCommandLine) const |
void | ShowCurrent (const G4String &) const |
void | TerminalHelp (const G4String &) |
Protected Attributes | |
G4int | ifBatch = 0 |
G4int | lastRC = 0 |
std::vector< Transformer > | transformersCerr |
std::vector< Transformer > | transformersCout |
Static Protected Attributes | |
static G4ICOMS_DLL G4int | inSession = 0 |
static G4MTGLOB_DLL G4coutDestination * | masterG4coutDestination = nullptr |
Private Member Functions | |
virtual void | ExecuteCommand (const G4String &aCommand) |
virtual void | ExitHelp () const |
G4String | GetCommand (const char *msg=0) |
virtual G4bool | GetHelpChoice (G4int &aInt) |
G4String | ModifyPath (const G4String &tempPath) const |
Private Attributes | |
G4String | currentDirectory |
G4bool | iCont |
G4bool | iExit |
G4VUIshell * | shell |
G4UImanager * | UI |
Definition at line 70 of file G4UIterminal.hh.
|
inherited |
Definition at line 61 of file G4coutDestination.hh.
G4UIterminal::G4UIterminal | ( | G4VUIshell * | aShell = 0 , |
G4bool | qsig = true |
||
) |
Definition at line 90 of file G4UIterminal.cc.
References FALSE, G4UImanager::GetUIpointer(), iCont, iExit, shell, SignalHandler(), theshell, and UI.
G4UIterminal::~G4UIterminal | ( | ) |
Definition at line 113 of file G4UIterminal.cc.
References G4UImanager::GetUIpointer(), shell, and UI.
|
inlineinherited |
Definition at line 67 of file G4coutDestination.hh.
References G4coutDestination::transformersCerr.
Referenced by G4MTcoutDestination::HandleFileCerr().
|
inlineinherited |
Definition at line 71 of file G4coutDestination.hh.
References G4coutDestination::transformersCerr.
|
inlineinherited |
Definition at line 62 of file G4coutDestination.hh.
References G4coutDestination::transformersCout.
Referenced by G4MTcoutDestination::AddMasterOutput(), G4MTcoutDestination::HandleFileCout(), and G4MTcoutDestination::SetDefaultOutput().
|
inlineinherited |
Definition at line 66 of file G4coutDestination.hh.
References G4coutDestination::transformersCout.
|
protectedinherited |
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Definition at line 232 of file G4VBasicShell.cc.
References G4VBasicShell::ChangeDirectoryCommand(), G4VBasicShell::ExecuteCommand(), exitPause, exitSession, G4cerr, G4cout, G4endl, G4VBasicShell::GetCurrentWorkingDirectory(), G4UImanager::GetNumberOfHistory(), G4UImanager::GetPreviousCommand(), G4UImanager::GetUIpointer(), G4VBasicShell::ListDirectory(), G4StrUtil::lstrip_copy(), G4VBasicShell::ModifyToFullPathCommand(), G4VBasicShell::ShowCurrent(), and G4VBasicShell::TerminalHelp().
Referenced by G4UIQt::ButtonCallback(), G4UIXm::ButtonCallback(), G4UIQt::CommandEnteredCallback(), G4UIXm::CommandEnteredCallback(), G4UIWin32::DoOpenMacro(), G4UIWin32::DoSaveViewer(), G4UIWin32::ProcessDefaultCommands(), and G4UIWin32::ProcessEnterKey().
|
protectedinherited |
Definition at line 74 of file G4VBasicShell.cc.
References G4VBasicShell::currentDirectory, G4VBasicShell::FindDirectory(), G4VBasicShell::ModifyPath(), and G4StrUtil::strip_copy().
Referenced by G4VBasicShell::ChangeDirectoryCommand().
|
protectedinherited |
Definition at line 325 of file G4VBasicShell.cc.
References G4VBasicShell::ChangeDirectory(), G4cout, G4endl, and G4StrUtil::strip_copy().
Referenced by G4VBasicShell::ApplyShellCommand(), GetCommand(), and G4ZMQServer::GetCommand().
Definition at line 180 of file G4VBasicShell.cc.
References G4VBasicShell::FindMatchingPath(), G4UImanager::GetTree(), G4UImanager::GetUIpointer(), G4VBasicShell::ModifyPath(), and G4StrUtil::strip_copy().
Referenced by G4UIQt::eventFilter(), G4UIXm::keyHandler(), and G4UIWin32::ProcessTabKey().
|
privatevirtual |
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Reimplemented from G4VBasicShell.
Definition at line 160 of file G4UIterminal.cc.
References fAliasNotFound, fCommandNotFound, fCommandSucceeded, fIllegalApplicationState, G4VBasicShell::FindCommand(), fParameterOutOfCandidates, fParameterOutOfRange, fParameterUnreadable, G4cerr, G4cout, G4endl, G4UIcommand::GetParameter(), G4UIparameter::GetParameterCandidates(), G4UImanager::SolveAlias(), and UI.
Referenced by PauseSessionStart(), and SessionStart().
|
privatevirtual |
Implements G4VBasicShell.
Definition at line 334 of file G4UIterminal.cc.
References G4cin.
|
protectedinherited |
Definition at line 109 of file G4VBasicShell.cc.
References G4UIcommandTree::FindPath(), G4UImanager::GetTree(), G4UImanager::GetUIpointer(), G4VBasicShell::ModifyPath(), and G4StrUtil::strip_copy().
Referenced by ExecuteCommand(), and G4ZMQServer::ExecuteCommand().
|
protectedinherited |
Definition at line 87 of file G4VBasicShell.cc.
References G4UImanager::GetTree(), G4UIcommandTree::GetTree(), G4UImanager::GetUIpointer(), G4VBasicShell::ModifyPath(), and G4StrUtil::strip_copy().
Referenced by G4VBasicShell::ChangeDirectory(), G4VBasicShell::ListDirectory(), and G4ZMQServer::SessionStart().
|
protectedinherited |
Definition at line 196 of file G4VBasicShell.cc.
Referenced by G4VBasicShell::Complete().
|
private |
Definition at line 211 of file G4UIterminal.cc.
References G4VBasicShell::ChangeDirectoryCommand(), FALSE, G4cerr, G4cout, G4endl, G4VUIshell::GetCommandLineString(), G4VBasicShell::GetCurrentWorkingDirectory(), G4UImanager::GetPreviousCommand(), iCont, iExit, G4VBasicShell::ListDirectory(), G4StrUtil::lstrip_copy(), G4VBasicShell::ModifyToFullPathCommand(), shell, G4VBasicShell::ShowCurrent(), G4VBasicShell::TerminalHelp(), and UI.
Referenced by PauseSessionStart(), and SessionStart().
|
protectedinherited |
Definition at line 69 of file G4VBasicShell.cc.
References G4VBasicShell::currentDirectory.
Referenced by G4VBasicShell::ApplyShellCommand(), GetCommand(), G4ZMQServer::GetCommand(), G4VBasicShell::ListDirectory(), G4ZMQServer::SessionStart(), and G4VBasicShell::TerminalHelp().
Implements G4VBasicShell.
Definition at line 321 of file G4UIterminal.cc.
|
inlineinherited |
|
staticinherited |
Definition at line 68 of file G4UIsession.cc.
References G4UIsession::inSession.
Referenced by G4UIcontrolMessenger::SetNewValue().
|
protectedinherited |
Definition at line 339 of file G4VBasicShell.cc.
References G4VBasicShell::FindDirectory(), G4cout, G4endl, G4VBasicShell::GetCurrentWorkingDirectory(), G4UIcommandTree::ListCurrent(), and G4StrUtil::strip_copy().
Referenced by G4VBasicShell::ApplyShellCommand(), GetCommand(), and G4ZMQServer::GetCommand().
Definition at line 124 of file G4VBasicShell.cc.
References G4VBasicShell::currentDirectory.
Referenced by G4VBasicShell::ChangeDirectory(), G4VBasicShell::Complete(), G4VBasicShell::FindCommand(), G4VBasicShell::FindDirectory(), and G4VBasicShell::ModifyToFullPathCommand().
|
protectedinherited |
Definition at line 47 of file G4VBasicShell.cc.
References G4VBasicShell::ModifyPath(), and G4StrUtil::strip_copy().
Referenced by G4UIQt::ActivateCommand(), G4VBasicShell::ApplyShellCommand(), GetCommand(), G4ZMQServer::GetCommand(), G4VBasicShell::ShowCurrent(), and G4VBasicShell::TerminalHelp().
|
virtual |
Implements G4VBasicShell.
Definition at line 147 of file G4UIterminal.cc.
References ExecuteCommand(), GetCommand(), iCont, and TRUE.
Reimplemented from G4UIsession.
Definition at line 313 of file G4UIterminal.cc.
Definition at line 84 of file G4coutDestination.cc.
References m, G4coutDestination::ReceiveG4cerr(), G4coutDestination::transformersCerr, and G4coutDestination::transformersCout.
Referenced by G4MasterForwardcoutDestination::ReceiveG4cerr().
Reimplemented from G4UIsession.
Definition at line 305 of file G4UIterminal.cc.
Definition at line 62 of file G4coutDestination.cc.
References m, G4coutDestination::ReceiveG4cout(), and G4coutDestination::transformersCout.
Referenced by G4MasterForwardcoutDestination::ReceiveG4cout().
|
virtualinherited |
Definition at line 41 of file G4coutDestination.cc.
References G4coutDestination::transformersCerr, and G4coutDestination::transformersCout.
|
virtual |
Implements G4VBasicShell.
Definition at line 133 of file G4UIterminal.cc.
References ExecuteCommand(), GetCommand(), iExit, and TRUE.
void G4UIterminal::SetPrompt | ( | const G4String & | prompt | ) |
Definition at line 126 of file G4UIterminal.cc.
References SetPrompt(), and shell.
Referenced by SetPrompt().
|
protectedinherited |
Definition at line 313 of file G4VBasicShell.cc.
References G4cout, G4endl, G4UImanager::GetCurrentValues(), G4UImanager::GetUIpointer(), and G4VBasicShell::ModifyToFullPathCommand().
Referenced by G4VBasicShell::ApplyShellCommand(), GetCommand(), and G4ZMQServer::GetCommand().
|
protectedinherited |
Definition at line 355 of file G4VBasicShell.cc.
References G4VBasicShell::ExitHelp(), G4UIcommandTree::FindPath(), G4cout, G4endl, G4UIcommandTree::GetCommand(), G4VBasicShell::GetCurrentWorkingDirectory(), G4VBasicShell::GetHelpChoice(), G4UImanager::GetTree(), G4UIcommandTree::GetTree(), G4UIcommandTree::GetTreeEntry(), G4UImanager::GetUIpointer(), G4UIcommand::List(), G4UIcommandTree::ListCurrentWithNum(), G4VBasicShell::ModifyToFullPathCommand(), and G4StrUtil::strip().
Referenced by G4VBasicShell::ApplyShellCommand(), GetCommand(), G4ZMQServer::GetCommand(), and G4UIQt::ShowHelpCallback().
|
privateinherited |
Definition at line 101 of file G4VBasicShell.hh.
Referenced by G4VBasicShell::ChangeDirectory(), G4VBasicShell::GetCurrentWorkingDirectory(), and G4VBasicShell::ModifyPath().
|
private |
Definition at line 78 of file G4UIterminal.hh.
Referenced by G4UIterminal(), GetCommand(), and PauseSessionStart().
|
private |
Definition at line 77 of file G4UIterminal.hh.
Referenced by G4UIterminal(), GetCommand(), and SessionStart().
|
protectedinherited |
Definition at line 68 of file G4UIsession.hh.
Referenced by G4UIsession::~G4UIsession().
|
staticprotectedinherited |
Definition at line 67 of file G4UIsession.hh.
Referenced by G4UIsession::G4UIsession(), G4UIsession::InSession(), and G4UIsession::~G4UIsession().
|
protectedinherited |
Definition at line 69 of file G4UIsession.hh.
Referenced by G4UIbatch::G4UIbatch(), G4UIsession::GetLastReturnCode(), and G4UIbatch::SessionStart().
|
staticprotectedinherited |
Definition at line 88 of file G4coutDestination.hh.
Referenced by G4UIQt::G4UIQt(), G4MasterForwardcoutDestination::ReceiveG4cerr(), G4MasterForwardcoutDestination::ReceiveG4cout(), and G4UIQt::~G4UIQt().
|
private |
Definition at line 74 of file G4UIterminal.hh.
Referenced by G4UIterminal(), GetCommand(), SetPrompt(), and ~G4UIterminal().
|
protectedinherited |
Definition at line 94 of file G4coutDestination.hh.
Referenced by G4coutDestination::AddCerrTransformer(), G4coutDestination::ReceiveG4cerr_(), and G4coutDestination::ResetTransformers().
|
protectedinherited |
Definition at line 93 of file G4coutDestination.hh.
Referenced by G4coutDestination::AddCoutTransformer(), G4coutDestination::ReceiveG4cerr_(), G4coutDestination::ReceiveG4cout_(), and G4coutDestination::ResetTransformers().
|
private |
Definition at line 72 of file G4UIterminal.hh.
Referenced by ExecuteCommand(), G4UIterminal(), GetCommand(), and ~G4UIterminal().