Geant4  10.02.p02
G4VUIshell Class Referenceabstract

#include <G4VUIshell.hh>

+ Inheritance diagram for G4VUIshell:
+ Collaboration diagram for G4VUIshell:

Public Member Functions

 G4VUIshell (const G4String &prompt="> ")
 
virtual ~G4VUIshell ()
 
void SetNColumn (G4int ncol)
 
void SetPrompt (const G4String &prompt)
 
void SetCurrentDirectory (const G4String &ccd)
 
virtual void SetLsColor (TermColorIndex, TermColorIndex)
 
virtual void ShowCurrentDirectory () const
 
virtual void ListCommand (const G4String &input, const G4String &candidate="") const
 
virtual G4String GetCommandLineString (const char *msg=0)=0
 
virtual void ResetTerminal ()
 

Protected Member Functions

virtual void MakePrompt (const char *msg=0)
 
G4UIcommandTreeGetCommandTree (const G4String &dir) const
 
G4String GetAbsCommandDirPath (const G4String &apath) const
 
G4String GetCommandPathTail (const G4String &apath) const
 

Protected Attributes

G4String promptSetting
 
G4String promptString
 
G4int nColumn
 
G4bool lsColorFlag
 
TermColorIndex directoryColor
 
TermColorIndex commandColor
 
G4String currentCommandDir
 

Detailed Description

Definition at line 59 of file G4VUIshell.hh.

Constructor & Destructor Documentation

G4VUIshell::G4VUIshell ( const G4String prompt = "> ")

Definition at line 46 of file G4VUIshell.cc.

G4VUIshell::~G4VUIshell ( )
virtual

Definition at line 55 of file G4VUIshell.cc.

Member Function Documentation

G4String G4VUIshell::GetAbsCommandDirPath ( const G4String apath) const
protected

Definition at line 147 of file G4VUIshell.cc.

References G4String::index(), G4String::last(), and G4String::remove().

Referenced by G4UItcsh::CompleteCommand(), and G4UItcsh::ListMatchedCommand().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

virtual G4String G4VUIshell::GetCommandLineString ( const char *  msg = 0)
pure virtual

Implemented in G4UItcsh, G4UIcsh, and G4UImpish.

G4String G4VUIshell::GetCommandPathTail ( const G4String apath) const
protected

Definition at line 193 of file G4VUIshell.cc.

References FALSE, and TRUE.

Referenced by G4UItcsh::CompleteCommand().

+ Here is the caller graph for this function:

G4UIcommandTree * G4VUIshell::GetCommandTree ( const G4String dir) const
protected

Definition at line 118 of file G4VUIshell.cc.

References G4String::both, G4UImanager::GetUIpointer(), G4String::index(), and G4String::strip().

Referenced by G4UItcsh::CompleteCommand().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4VUIshell::ListCommand ( const G4String input,
const G4String candidate = "" 
) const
virtual

Definition at line 231 of file G4VUIshell.cc.

References G4String::both, FALSE, G4cout, G4endl, G4String::index(), G4UIArrayString::Show(), G4String::strip(), and TRUE.

Referenced by G4UItcsh::ListMatchedCommand().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4VUIshell::MakePrompt ( const char *  msg = 0)
protectedvirtual

Reimplemented in G4UItcsh.

Definition at line 61 of file G4VUIshell.cc.

References G4String::append(), currentCommandDir, G4StateManager::GetCurrentState(), G4StateManager::GetStateManager(), promptSetting, and promptString.

Referenced by G4UIcsh::GetCommandLineString().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4VUIshell::ResetTerminal ( )
virtual

Reimplemented in G4UItcsh.

Definition at line 108 of file G4VUIshell.cc.

void G4VUIshell::SetCurrentDirectory ( const G4String ccd)
inline

Definition at line 115 of file G4VUIshell.hh.

References currentCommandDir.

void G4VUIshell::SetLsColor ( TermColorIndex  ,
TermColorIndex   
)
inlinevirtual

Reimplemented in G4UItcsh.

Definition at line 120 of file G4VUIshell.hh.

void G4VUIshell::SetNColumn ( G4int  ncol)
inline

Definition at line 105 of file G4VUIshell.hh.

References nColumn.

void G4VUIshell::SetPrompt ( const G4String prompt)
inline

Definition at line 110 of file G4VUIshell.hh.

References promptSetting.

void G4VUIshell::ShowCurrentDirectory ( ) const
inlinevirtual

Definition at line 124 of file G4VUIshell.hh.

References currentCommandDir, G4cout, and G4endl.

Member Data Documentation

TermColorIndex G4VUIshell::commandColor
protected

Definition at line 70 of file G4VUIshell.hh.

Referenced by G4UItcsh::SetLsColor().

TermColorIndex G4VUIshell::directoryColor
protected

Definition at line 69 of file G4VUIshell.hh.

Referenced by G4UItcsh::SetLsColor().

G4bool G4VUIshell::lsColorFlag
protected

Definition at line 68 of file G4VUIshell.hh.

Referenced by G4UItcsh::SetLsColor().

G4int G4VUIshell::nColumn
protected

Definition at line 64 of file G4VUIshell.hh.

Referenced by SetNColumn().

G4String G4VUIshell::promptSetting
protected

Definition at line 61 of file G4VUIshell.hh.

Referenced by MakePrompt(), G4UItcsh::MakePrompt(), and SetPrompt().


The documentation for this class was generated from the following files: