Geant4  10.02.p03
G4UIGainServer Class Reference

#include <G4UIGainServer.hh>

Inheritance diagram for G4UIGainServer:
Collaboration diagram for G4UIGainServer:

Public Member Functions

G4UIsessionSessionStart ()
 
virtual void PauseSessionStart (const G4String &msg)
 
virtual G4int ReceiveG4cout (const G4String &coutString)
 
virtual G4int ReceiveG4cerr (const G4String &cerrString)
 
 G4UIGainServer ()
 
 ~G4UIGainServer ()
 
void SessionTerminate ()
 
void Prompt (G4String)
 
G4String GetCommand ()
 
- Public Member Functions inherited from G4VBasicShell
 G4VBasicShell ()
 
virtual ~G4VBasicShell ()
 
- Public Member Functions inherited from G4UIsession
 G4UIsession ()
 
virtual ~G4UIsession ()
 
- Public Member Functions inherited from G4coutDestination
 G4coutDestination ()
 
virtual ~G4coutDestination ()
 

Private Member Functions

void GetNewTreeStructure (G4UIcommandTree *, int recursiveLevel)
 
void GetNewTreeValues (G4UIcommandTree *, int recursiveLevel)
 
virtual void ExecuteCommand (const G4String &aCommand)
 
virtual G4bool GetHelpChoice (G4int &aInt)
 
virtual void ExitHelp () const
 
bool SetUPServer ()
 
void WaitingConnection ()
 
void CloseConnection ()
 
void ChangeDirectory (G4String)
 
void ListDirectory (G4String)
 
void TerminalHelp (G4String)
 
G4String ModifyPrefix (G4String)
 
G4UIcommandTreeFindDirPath (G4String)
 
void ShowCurrent (G4String)
 
G4String GetFullPath (G4String)
 
void SendCommandProperties (G4UIcommandTree *)
 
void SendParameterProperties (G4UIcommandTree *)
 
void SendAParamProperty (G4UIcommand *)
 
void SendATclParamProperty (G4UIcommand *)
 
void CodeGenJavaTree (G4UIcommandTree *, int recursiveLevel)
 
void CodeGenJavaParams (G4UIcommandTree *, int recursiveLevel)
 
void CodeGenTclTree (G4UIcommandTree *, int recursiveLevel)
 
void CodeGenTclParams (G4UIcommandTree *, int recursiveLevel)
 
void SendDisableList (G4UIcommandTree *, int recursiveLevel)
 
void NotifyStateChange (void)
 
void NotifyCommandUpdate (void)
 
void NotifyParameterUpdate (G4UIcommand *)
 
int CommandUpdated (void)
 
void UpdateState (void)
 
void UpdateParamVal (void)
 

Private Attributes

G4String prefix
 
G4String promptCharacter
 
G4UImanagerUI
 
UImode uiMode
 
G4String JVersion
 
G4String TVersion
 
G4bool iExit
 
G4bool iCont
 
int socketD [3]
 
int port
 
struct sockaddr_in saddr
 
struct sockaddr_in caddr
 
int len
 
int ret
 
char buf [1024]
 
std::vector< G4StringpreviousTreeCommands
 
std::vector< G4StringnewTreeCommands
 
std::vector< G4StringpreviousTreeParams
 
std::vector< G4StringnewTreeParams
 
std::vector< G4UIcommand * > previousTreePCP
 
std::vector< G4UIcommand * > newTreePCP
 

Additional Inherited Members

- Protected Member Functions inherited from G4VBasicShell
G4String ModifyToFullPathCommand (const char *aCommandLine) const
 
G4String GetCurrentWorkingDirectory () const
 
G4bool ChangeDirectory (const char *newDir)
 
G4UIcommandTreeFindDirectory (const char *dirName) const
 
G4UIcommandFindCommand (const char *commandName) const
 
G4String Complete (const G4String &)
 
G4String FindMatchingPath (G4UIcommandTree *, const G4String &)
 
void ApplyShellCommand (const G4String &, G4bool &, G4bool &)
 
void ShowCurrent (const G4String &) const
 
void ChangeDirectoryCommand (const G4String &)
 
void ListDirectory (const G4String &) const
 
void TerminalHelp (const G4String &)
 
- Static Protected Attributes inherited from G4coutDestination
static G4coutDestinationmasterG4coutDestination = 0
 

Detailed Description

Definition at line 64 of file G4UIGainServer.hh.

Constructor & Destructor Documentation

◆ G4UIGainServer()

G4UIGainServer::G4UIGainServer ( )

Definition at line 43 of file G4UIGainServer.cc.

45 {
46  TVersion ="T1.0a"; JVersion="J1.0a";
47  prefix = "/";
48 
50  while(SetUPServer() == false){
51  G4cout<<"can't get the port no. "<<port<<" Now, try to get the next port "<<port+1<<G4endl;
52  port++;
53  }
54 
55 
57  UI-> SetSession(this);
58  UI-> SetCoutDestination(this);
59 
63 
64  iExit= FALSE;
65  iCont= FALSE;
66 
68  GetNewTreeStructure(tree,0);
69  GetNewTreeValues(tree,0);
73 
74 }
std::vector< G4UIcommand * > newTreePCP
std::vector< G4String > previousTreeCommands
G4String GetStateString(G4ApplicationState aState) const
static G4UImanager * GetUIpointer()
Definition: G4UImanager.cc:58
G4UImanager * UI
void GetNewTreeStructure(G4UIcommandTree *, int recursiveLevel)
static G4StateManager * GetStateManager()
std::vector< G4UIcommand * > previousTreePCP
G4GLOB_DLL std::ostream G4cout
#define FALSE
Definition: globals.hh:52
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
std::vector< G4String > previousTreeParams
std::vector< G4String > newTreeCommands
#define DEFAULT_PORT
#define G4endl
Definition: G4ios.hh:61
void GetNewTreeValues(G4UIcommandTree *, int recursiveLevel)
std::vector< G4String > newTreeParams
G4ApplicationState GetCurrentState() const
G4String promptCharacter
Here is the call graph for this function:

◆ ~G4UIGainServer()

G4UIGainServer::~G4UIGainServer ( )

Definition at line 77 of file G4UIGainServer.cc.

79 {
80 
82  UI-> SetSession(NULL);
83  UI-> SetCoutDestination(NULL);
84  }
85 
87  UI->SetSession(NULL);
88  UI->SetCoutDestination(NULL);
89  }
90 }
void SetSession(G4UIsession *const value)
Definition: G4UImanager.hh:213
static G4UImanager * GetUIpointer()
Definition: G4UImanager.cc:58
G4UImanager * UI
void SetCoutDestination(G4UIsession *const value)
Definition: G4UImanager.cc:618
Here is the call graph for this function:

Member Function Documentation

◆ ChangeDirectory()

void G4UIGainServer::ChangeDirectory ( G4String  newCommand)
private

Definition at line 476 of file G4UIGainServer.cc.

476  {
478  G4String savedPrefix = prefix;
479  if( newCommand.length() <= 3 )
480  { prefix = "/"; }
481  else
482  {
483  G4String aNewPrefix = newCommand(3,newCommand.length()-3);
484  G4String newPrefix = aNewPrefix.strip(G4String::both);
485  if( newPrefix(0) == '/' )
486  { prefix = newPrefix; }
487  else if( newPrefix(0) != '.' )
488  {
489  prefix += newPrefix;
490  }
491  else
492  { prefix = ModifyPrefix( newPrefix ); }
493  }
494  if( prefix( prefix.length() - 1 ) != '/' )
495  { prefix += "/"; }
496  if( FindDirPath( prefix ) == NULL )
497  {
498  G4cout << "Directory <" << prefix << "> is not found." << G4endl;
499  prefix = savedPrefix;
500  }
501 }
G4UIcommandTree * FindDirPath(G4String)
G4String strip(G4int strip_Type=trailing, char c=' ')
G4GLOB_DLL std::ostream G4cout
G4String ModifyPrefix(G4String)
#define G4endl
Definition: G4ios.hh:61
Here is the call graph for this function:
Here is the caller graph for this function:

◆ CloseConnection()

void G4UIGainServer::CloseConnection ( )
private

◆ CodeGenJavaParams()

void G4UIGainServer::CodeGenJavaParams ( G4UIcommandTree tree,
int  recursiveLevel 
)
private

Definition at line 690 of file G4UIGainServer.cc.

690  {
692  int treeEntry,commandEntry,i;
693  G4UIcommandTree* treeLink;
694 
695  treeEntry = tree->GetTreeEntry();
696  commandEntry = tree->GetCommandEntry();
697 
698  for(i=0;i<commandEntry; i++){
699  SendAParamProperty(tree->GetCommand(i+1));
700  }
701  if(treeEntry ==0) return;
702 
703  for(i=0;i<treeEntry; i++){
704  treeLink = tree->GetTree(i+1);
705  G4cout<<"@@JDirGuieBegin"<<G4endl;
706  G4cout<<treeLink->GetPathName()<<G4endl <<treeLink->GetTitle()<<G4endl;
707  G4cout<<"@@JDirGuideEnd"<<G4endl;
708  CodeGenJavaParams(treeLink,level+1);
709  }
710 }
G4UIcommand * GetCommand(G4int i)
void CodeGenJavaParams(G4UIcommandTree *, int recursiveLevel)
const G4String GetPathName() const
G4int GetCommandEntry() const
void SendAParamProperty(G4UIcommand *)
G4GLOB_DLL std::ostream G4cout
G4UIcommandTree * GetTree(G4int i)
#define G4endl
Definition: G4ios.hh:61
G4int GetTreeEntry() const
const G4String GetTitle() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ CodeGenJavaTree()

void G4UIGainServer::CodeGenJavaTree ( G4UIcommandTree tree,
int  recursiveLevel 
)
private

Definition at line 671 of file G4UIGainServer.cc.

671  {
673  int treeEntry, commandEntry;
674  treeEntry = tree->GetTreeEntry();
675  commandEntry = tree->GetCommandEntry();
676 
677  if(level!=0) {
678  for(int i=0; i<commandEntry; i++){
679  G4cout << tree->GetCommand(i+1)->GetCommandPath() << G4endl;
680  }
681  }
682  if(treeEntry == 0) return; //end recursion
683 
684  for(int j=0; j<treeEntry; j++){
685  CodeGenJavaTree(tree->GetTree(j+1), level+1);
686  }
687 }
void CodeGenJavaTree(G4UIcommandTree *, int recursiveLevel)
G4UIcommand * GetCommand(G4int i)
G4int GetCommandEntry() const
G4GLOB_DLL std::ostream G4cout
G4UIcommandTree * GetTree(G4int i)
const G4String & GetCommandPath() const
Definition: G4UIcommand.hh:139
#define G4endl
Definition: G4ios.hh:61
G4int GetTreeEntry() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ CodeGenTclParams()

void G4UIGainServer::CodeGenTclParams ( G4UIcommandTree ,
int  recursiveLevel 
)
private

◆ CodeGenTclTree()

void G4UIGainServer::CodeGenTclTree ( G4UIcommandTree ,
int  recursiveLevel 
)
private

◆ CommandUpdated()

int G4UIGainServer::CommandUpdated ( void  )
private

Definition at line 827 of file G4UIGainServer.cc.

827  {
829  int added=0, deleted=0;
830  int pEntry= previousTreeCommands.size();
831  int nEntry= newTreeCommands.size();
832  int i,j;
833  for( i=0; i<pEntry; i++) { // check deleted command(s)
834  for( j=0; j<nEntry; j++) {
835  if( previousTreeCommands[i] == newTreeCommands[j]) break;
836  }
837  if( j==nEntry ) {
838  deleted = 1;
839  //G4cout <<"deleted: "<< previousTreeCommands(i) << G4endl;
840  }
841  }
842  for( i=0; i<nEntry; i++) { // check added command(s)
843  for( j=0; j<pEntry; j++) {
844  if( newTreeCommands[i] == previousTreeCommands[j]) break;
845  }
846  if( j==pEntry ) {
847  added = 1;
848  // G4cout <<"added: "<< newTreeCommands(i) << G4endl;
849  }
850  }
851  if( added && deleted==0 ) {G4cout<<"c added"<<G4endl;return added;}
852  if( added==0 && deleted ) {G4cout<<"c deleted"<<G4endl;return deleted;}
853  if( added && deleted ) {G4cout<<"c add/deleted"<<G4endl;return addedAndDeleted;}
854  return notChanged;
855 }
std::vector< G4String > previousTreeCommands
Definition: G4UIGAG.hh:45
G4GLOB_DLL std::ostream G4cout
std::vector< G4String > newTreeCommands
#define G4endl
Definition: G4ios.hh:61
Here is the caller graph for this function:

◆ ExecuteCommand()

void G4UIGainServer::ExecuteCommand ( const G4String aCommand)
privatevirtual

Reimplemented from G4VBasicShell.

Definition at line 131 of file G4UIGainServer.cc.

133 {
134  if(aCommand.length()<2) return;
135 
137  if(aCommand.length()<2) return;
138  G4int returnVal = UI->ApplyCommand(aCommand);
139  G4int paramIndex = returnVal % 100;
140  // 0 - 98 : paramIndex-th parameter is invalid
141  // 99 : convination of parameters is invalid
142  G4int commandStatus = returnVal - paramIndex;
143 
144  UpdateState();
145 
146  if(uiMode != terminal_mode){
147  switch(commandStatus) {
148  case fCommandSucceeded:
149  GetNewTreeStructure(tree,0);
150  GetNewTreeValues(tree,0);
151  if(CommandUpdated()){
153  } else{
154  UpdateParamVal();
155  }
159  break;
160  case fCommandNotFound:
161  G4cerr << "@@ErrResult \" <" << UI->SolveAlias(aCommand) << "> not found.\"" << G4endl;
162  break;
164  G4cerr << "@@ErrResult \"illegal application state -- command refused.\"" << G4endl;
165  break;
167  G4cout << "@@ErrResult \"Parameter Out of Range.\"" << G4endl;
168  break;
170  G4cout << "@@ErrResult \"Parameter is wrong type and/or is not omittable.\""<<G4endl;
171  break;
173  G4cerr << "@@ErrResult \"Parameter is out of candidate.\"" << G4endl;
174  break;
175  case fAliasNotFound:
176  default:
177  G4cerr << "command refused (" << commandStatus << ")" << G4endl;
178  }
179  }
180 }
std::vector< G4UIcommand * > newTreePCP
std::vector< G4String > previousTreeCommands
int G4int
Definition: G4Types.hh:78
G4UImanager * UI
void GetNewTreeStructure(G4UIcommandTree *, int recursiveLevel)
std::vector< G4UIcommand * > previousTreePCP
G4GLOB_DLL std::ostream G4cout
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
std::vector< G4String > previousTreeParams
std::vector< G4String > newTreeCommands
int CommandUpdated(void)
G4String SolveAlias(const char *aCmd)
Definition: G4UImanager.cc:391
#define G4endl
Definition: G4ios.hh:61
void NotifyCommandUpdate(void)
void GetNewTreeValues(G4UIcommandTree *, int recursiveLevel)
std::vector< G4String > newTreeParams
void UpdateParamVal(void)
void UpdateState(void)
G4int ApplyCommand(const char *aCommand)
Definition: G4UImanager.cc:446
G4GLOB_DLL std::ostream G4cerr
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ExitHelp()

void G4UIGainServer::ExitHelp ( ) const
privatevirtual

Implements G4VBasicShell.

Definition at line 353 of file G4UIGainServer.cc.

355 {
356  char temp[100];
357  G4cin.getline(temp, 100);
358 }
#define G4cin
Definition: G4ios.hh:60

◆ FindDirPath()

G4UIcommandTree * G4UIGainServer::FindDirPath ( G4String  newCommand)
private

Definition at line 626 of file G4UIGainServer.cc.

626  {
628  G4UIcommandTree * comTree = UI->GetTree();
629  /*int*/ unsigned idx = 1;
630  while( idx < newCommand.length()-1 )
631  {
632  int i = newCommand.index("/",idx);
633  comTree = comTree->GetTree(G4String(newCommand(0,i+1)));
634  if( comTree == NULL )
635  { return NULL; }
636  idx = i+1;
637  }
638  return comTree;
639 }
str_size index(const char *, G4int pos=0) const
G4UImanager * UI
G4UIcommandTree * GetTree(G4int i)
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetCommand()

G4String G4UIGainServer::GetCommand ( )

Definition at line 183 of file G4UIGainServer.cc.

185 {
186  G4String newCommand;
187  G4String nullString;
188 
189  while( 1 )
190  {
192  if ( uiMode != terminal_mode ){
193  G4cout << "@@PROMPT \"" << promptCharacter << "\"" << G4endl;
194  }
195  if ( uiMode != java_mode ){
196  G4cout << promptCharacter << "> " << G4endl;
197  }else{
198  G4cout << "@@Ready" << G4endl;
199  }
200 
201 
204  read(socketD[1],buf,1024);
205  newCommand=buf;
206  //DEBUG cout<<"->"<<newCommand<<"<-"<<newCommand.length()<<G4endl;
207  //newCommand.readLine( G4cin, FALSE );
210 
211 
212 
213  if (!G4cin.good()) { G4cin.clear(); newCommand = nullString; iExit=false;break;}
214 
215  newCommand = newCommand.strip(G4String::leading);
216  if( newCommand.length() < 1) { break; }
217 
218  while( newCommand(newCommand.length()-1) == '_' )
219  {
220  G4String newLine;
221  newCommand.remove(newCommand.length()-1);
222  newLine.readLine( G4cin );
223  if (!G4cin.good()) { G4cin.clear(); newCommand = nullString; iExit=false;break;}
224  newCommand.append(newLine);
225  }
226 
227  G4String nC = newCommand.strip(G4String::leading);
228  if( nC.length() < 1) { break; }
229 
230  // -------------------- nC.toUpper();
231  if( nC == "@@GainmodeJAVA" ) {
232  uiMode = java_mode;
233  G4cout << G4endl << "@@Version " << JVersion << G4endl;
234  SendCommandProperties(tree);
236  }
237  else if( nC == "@@GainmodeTcl" ) {
238  uiMode = tcl_mode;
239  G4cout << G4endl << "@@Version " << TVersion << G4endl;
240  SendCommandProperties(tree);
242  }
243  else if( nC(0) == '#' )
244  { G4cout << nC << G4endl; }
245 
246  else if( nC == "ls" || nC(0,3) == "ls " )
247  { ListDirectory( nC ); }
248  else if( nC == "pwd" )
249  { G4cout << "Current Working Directory : " << prefix << G4endl; }
250  else if( nC(0,2) == "cd" || nC(0,3) == "cd " )
251  { ChangeDirectory( nC ); }
252  else if( nC == "help" || nC(0,5) == "help ")
253  { TerminalHelp( nC ); }
254  else if( nC(0) == '?' )
255  { ShowCurrent( nC ); }
256  else if( nC(0,4) == "hist" || nC == "history")
257  {
258  G4int nh = UI->GetNumberOfHistory();
259  for(int i=0;i<nh;i++)
260  { G4cout << i << ": " << UI->GetPreviousCommand(i) << G4endl; }
261  }
262  else if( nC(0) == '!' )
263  {
264  G4String ss = nC(1,nC.length()-1);
265  G4int vl;
266  const char* tt = ss;
267  std::istringstream is((char*)tt);
268  is >> vl;
269  G4int nh = UI->GetNumberOfHistory();
270  if(vl>=0 && vl<nh)
271  {
272  newCommand = UI->GetPreviousCommand(vl);
273  G4cout << newCommand << G4endl;
274  break;
275  }
276  else
277  { G4cerr << "history " << vl << " is not found." << G4endl; }
278  }
279  else if( nC(0,4) == "exit" )
280  {
281  if( iCont )
282  {
283  if ( uiMode == terminal_mode){
284  G4cerr << "You are now processing RUN." << G4endl;
285  G4cerr << "Please abrot it using \"/run/abort\" command first" << G4endl;
286  G4cerr << " and use \"continue\" command until the application" << G4endl;
287  G4cerr << " becomes to Idle." << G4endl;
288  }else{
289  G4cout << "@@ErrResult \"You are now processing RUN.\"" << G4endl;
290  }
291  }
292  else
293  {
294  close(socketD[1]);
295  close(socketD[2]);
296  iExit = false;
297  newCommand = nullString;
298  break;
299  }
300  }
301  else if( nC == "cont" || nC == "continue" )
302  {
303  iCont = false;
304  newCommand = nullString;
305  break;
306  }
307  else
308  { break; }
309  }
310  return GetFullPath(newCommand);
311 }
G4String & remove(str_size)
void TerminalHelp(G4String)
G4String strip(G4int strip_Type=trailing, char c=' ')
std::istream & readLine(std::istream &, G4bool skipWhite=true)
int G4int
Definition: G4Types.hh:78
G4UImanager * UI
#define G4cin
Definition: G4ios.hh:60
G4GLOB_DLL std::ostream G4cout
void SendCommandProperties(G4UIcommandTree *)
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
void ShowCurrent(G4String)
G4int GetNumberOfHistory() const
Definition: G4UImanager.hh:229
char buf[1024]
G4String & append(const G4String &)
in close()
#define G4endl
Definition: G4ios.hh:61
G4String GetFullPath(G4String)
void NotifyStateChange(void)
G4String GetPreviousCommand(G4int i) const
Definition: G4UImanager.hh:231
void ChangeDirectory(G4String)
G4String promptCharacter
G4GLOB_DLL std::ostream G4cerr
void ListDirectory(G4String)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetFullPath()

G4String G4UIGainServer::GetFullPath ( G4String  aNewCommand)
private

Definition at line 418 of file G4UIGainServer.cc.

418  {
420  G4String newCommand = aNewCommand.strip(G4String::both);
421  G4String tmpString;
422  if( newCommand(0) == '/' )
423  { tmpString = newCommand; }
424  else if( newCommand(0,3) == "../" )
425  {
426  G4String tmpPrefix = prefix;
427  /*G4int*/ unsigned i_direc = 0;
428  while( i_direc < newCommand.length() )
429  {
430  if( newCommand(i_direc,3) == "../" )
431  {
432  i_direc += 3;
433  prefix = ModifyPrefix( G4String("../") );
434  }
435  else
436  { break; }
437  }
438  tmpString = prefix;
439  tmpString.append( newCommand( i_direc, newCommand.length()-i_direc ) );
440  prefix = tmpPrefix;
441  }
442  else
443  {
444  tmpString = prefix;
445  tmpString.append( newCommand );
446  }
447  return tmpString;
448 }
G4String strip(G4int strip_Type=trailing, char c=' ')
G4String ModifyPrefix(G4String)
G4String & append(const G4String &)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetHelpChoice()

G4bool G4UIGainServer::GetHelpChoice ( G4int aInt)
privatevirtual

Implements G4VBasicShell.

Definition at line 340 of file G4UIGainServer.cc.

342 {
343  G4cin >> aInt;
344  if(!G4cin.good()){
345  G4cin.clear();
346  G4cin.ignore(30,'\n');
347  return FALSE;
348  }
349  return TRUE;
350 }
#define G4cin
Definition: G4ios.hh:60
#define FALSE
Definition: globals.hh:52
#define TRUE
Definition: globals.hh:55

◆ GetNewTreeStructure()

void G4UIGainServer::GetNewTreeStructure ( G4UIcommandTree tree,
int  recursiveLevel 
)
private

Definition at line 858 of file G4UIGainServer.cc.

858  {
860  G4String commandPath;
861  G4String title;
862  G4String pathName; //tree name
863  G4UIcommandTree * t;
864  int treeEntry = tree->GetTreeEntry();
865  int commandEntry = tree->GetCommandEntry();
866 
867  if( level==0 ) { newTreeCommands.clear();}
868  for(int com=0; com<commandEntry; com++){
869  commandPath = tree->GetCommand(com+1)->GetCommandPath();
870  title = tree->GetCommand(com+1)->GetTitle();
871  newTreeCommands.push_back( commandPath + " " + title );
872  }
873 
874  if(treeEntry == 0) return; //end recursion
875 
876  for(int i=0; i< treeEntry; i++){
877  t = tree->GetTree(i+1);
878  pathName = t->GetPathName();
879  title = t->GetTitle();
880  newTreeCommands.push_back( pathName + " " + title );
881  GetNewTreeStructure(t, level+1);
882  }
883 }
G4UIcommand * GetCommand(G4int i)
const G4String GetTitle() const
Definition: G4UIcommand.hh:170
const G4String GetPathName() const
G4int GetCommandEntry() const
void GetNewTreeStructure(G4UIcommandTree *, int recursiveLevel)
G4UIcommandTree * GetTree(G4int i)
std::vector< G4String > newTreeCommands
const G4String & GetCommandPath() const
Definition: G4UIcommand.hh:139
G4int GetTreeEntry() const
subroutine title
Definition: hijing1.383.f:5981
const G4String GetTitle() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetNewTreeValues()

void G4UIGainServer::GetNewTreeValues ( G4UIcommandTree tree,
int  recursiveLevel 
)
private

Definition at line 907 of file G4UIGainServer.cc.

907  { // recursive
909  G4String commandPath;
910  G4String pathName; //tree name
911  G4UIcommandTree * t;
912  int parameterEntry;
913  int treeEntry = tree->GetTreeEntry();
914  int commandEntry = tree->GetCommandEntry();
915  G4UIcommand * Comp;
916  G4UIparameter * prp;
917  G4String param, str(" ");
918 
919  if( level==0 ) { newTreeParams.clear(); }
920  for(int com=0; com<commandEntry; com++) {
921  Comp = tree->GetCommand(com+1);
922  commandPath = Comp->GetCommandPath();
923  parameterEntry = Comp->GetParameterEntries();
924  param = commandPath +" ";
925  for( int par=0; par< parameterEntry; par++) {
926  prp = (G4UIparameter *)Comp->GetParameter(par);
927  param += prp->GetParameterName() +" ";
928  str(0) = prp->GetParameterType();
929  param += str + " ";
930  param += prp->GetDefaultValue() +" ";
931  param += prp->GetParameterRange() +" ";
932  param += prp->GetParameterCandidates();
933  }
934  newTreeParams.push_back( param + "\n");
935  newTreePCP.push_back( Comp );
936  }
937  if( treeEntry == 0 ) return; // end recursion
938  for( int i=0; i< treeEntry; i++) {
939  t = tree->GetTree(i+1);
940  GetNewTreeValues(t, level+1);
941  }
942 }
std::vector< G4UIcommand * > newTreePCP
G4String GetDefaultValue() const
G4String GetParameterRange() const
G4UIcommand * GetCommand(G4int i)
char GetParameterType() const
G4UIparameter * GetParameter(G4int i) const
Definition: G4UIcommand.hh:145
G4int GetCommandEntry() const
G4UIcommandTree * GetTree(G4int i)
G4String GetParameterName() const
G4String GetParameterCandidates() const
const G4String & GetCommandPath() const
Definition: G4UIcommand.hh:139
G4int GetParameterEntries() const
Definition: G4UIcommand.hh:143
void GetNewTreeValues(G4UIcommandTree *, int recursiveLevel)
std::vector< G4String > newTreeParams
G4int GetTreeEntry() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ListDirectory()

void G4UIGainServer::ListDirectory ( G4String  newCommand)
private

Definition at line 503 of file G4UIGainServer.cc.

503  {
505  G4String targetDir('\0');
506  if( newCommand.length() <= 3 )
507  { targetDir = prefix; }
508  else
509  {
510  G4String newPrefix = newCommand(3,newCommand.length()-3);
511  newPrefix.strip(G4String::both);
512  if( newPrefix(0) == '/' )
513  { targetDir = newPrefix; }
514  else if( newPrefix(0) != '.' )
515  {
516  targetDir = prefix;
517  targetDir += newPrefix;
518  }
519  else
520  { targetDir = ModifyPrefix( newPrefix ); }
521  }
522  if( targetDir( targetDir.length() - 1 ) != '/' )
523  { targetDir += "/"; }
524  G4UIcommandTree * commandTree = FindDirPath( targetDir );
525  if( commandTree == NULL )
526  { G4cout << "Directory <" << targetDir << "> is not found." << G4endl; }
527  else
528  { commandTree->ListCurrent(); }
529 }
G4UIcommandTree * FindDirPath(G4String)
G4String strip(G4int strip_Type=trailing, char c=' ')
G4GLOB_DLL std::ostream G4cout
G4String ModifyPrefix(G4String)
#define G4endl
Definition: G4ios.hh:61
void ListCurrent() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ModifyPrefix()

G4String G4UIGainServer::ModifyPrefix ( G4String  newCommand)
private

Definition at line 603 of file G4UIGainServer.cc.

603  {
605  G4String newPrefix = prefix;
606  while(1){
607  if(newCommand(0,2) ==".."){
608  if(newPrefix !="/"){
609  G4String tmpString = newPrefix(0,newPrefix.length()-1);
610  newPrefix = newPrefix(0,tmpString.last('/')+1);
611  }
612  }
613  else{
614  newPrefix += newCommand;
615  break;
616  }
617  if(newCommand == ".." || newCommand == "../"){
618  break;
619  }
620  newCommand=newCommand(3,newCommand.length()-3);
621  }
622  return newPrefix;
623 }
G4int last(char) const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ NotifyCommandUpdate()

void G4UIGainServer::NotifyCommandUpdate ( void  )
private

Definition at line 812 of file G4UIGainServer.cc.

814 {
816  SendCommandProperties(tree);
817 }
G4UImanager * UI
void SendCommandProperties(G4UIcommandTree *)
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
Here is the call graph for this function:
Here is the caller graph for this function:

◆ NotifyParameterUpdate()

void G4UIGainServer::NotifyParameterUpdate ( G4UIcommand com)
private

Definition at line 820 of file G4UIGainServer.cc.

822 {
823  SendAParamProperty(com);
824 }
void SendAParamProperty(G4UIcommand *)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ NotifyStateChange()

void G4UIGainServer::NotifyStateChange ( void  )
private

Definition at line 796 of file G4UIGainServer.cc.

798 {
799  G4String stateString;
802  stateString = statM->GetStateString(statM->GetCurrentState());
803  if ( uiMode != terminal_mode ){
804  G4cout << "@@State \"" << stateString << "\"" << G4endl;
805  G4cout << "@@DisableListBegin"<<G4endl;
806  SendDisableList(tree, 0);
807  G4cout << "@@DisableListEnd" <<G4endl;
808  }
809 }
G4String GetStateString(G4ApplicationState aState) const
G4UImanager * UI
static G4StateManager * GetStateManager()
G4GLOB_DLL std::ostream G4cout
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
#define G4endl
Definition: G4ios.hh:61
G4ApplicationState GetCurrentState() const
void SendDisableList(G4UIcommandTree *, int recursiveLevel)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ PauseSessionStart()

void G4UIGainServer::PauseSessionStart ( const G4String msg)
virtual

Implements G4VBasicShell.

Definition at line 113 of file G4UIGainServer.cc.

115 {
116  promptCharacter = msg;
117  G4cout<<"@@PROMPT \""<<promptCharacter<<"\""<<G4endl;
118 
119  iCont= TRUE;
120 
121  G4String newCommand= GetCommand();
122  while(iCont){
123  ExecuteCommand(newCommand);
124  newCommand= GetCommand();
125  strcpy(buf,"nowIdle");
126  write(socketD[1],buf,strlen(buf));
127  }
128 }
virtual void ExecuteCommand(const G4String &aCommand)
G4GLOB_DLL std::ostream G4cout
#define TRUE
Definition: globals.hh:55
char buf[1024]
G4String GetCommand()
#define G4endl
Definition: G4ios.hh:61
G4String promptCharacter
Here is the call graph for this function:

◆ Prompt()

void G4UIGainServer::Prompt ( G4String  )

◆ ReceiveG4cerr()

G4int G4UIGainServer::ReceiveG4cerr ( const G4String cerrString)
virtual

Reimplemented from G4UIsession.

Definition at line 327 of file G4UIGainServer.cc.

329 {
330  if(socketD[2]>0){
331  write(socketD[2],cerrString,cerrString.length());
332  }
333  return 0;
334 
335  //std::cerr << cerrString << std::flush;
336  //return 0;
337 }

◆ ReceiveG4cout()

G4int G4UIGainServer::ReceiveG4cout ( const G4String coutString)
virtual

Reimplemented from G4UIsession.

Definition at line 314 of file G4UIGainServer.cc.

316 {
317  if(socketD[1]>0){
318  write(socketD[1],coutString,coutString.length());
319  }
320  return 0;
321 
322  //std::cout << coutString << std::flush;
323  //return 0;
324 }

◆ SendAParamProperty()

void G4UIGainServer::SendAParamProperty ( G4UIcommand Comp)
private

Definition at line 713 of file G4UIGainServer.cc.

713  {
715  int guidanceEntry, parameterEntry;
716  G4String title, title2;
717  G4UIparameter * prp;
718  char c[2];
719  guidanceEntry = Comp->GetGuidanceEntries();
720  parameterEntry = Comp->GetParameterEntries();
721  G4cout << "@@JParamBegin" << G4endl;
722  G4cout << Comp->GetCommandPath() << G4endl;
723  G4cout << guidanceEntry << G4endl;
724  for (int j=0; j<guidanceEntry; j++){
725  title = Comp->GetGuidanceLine(j);
726  title2 = "";
727  if (title != ""){
728  for(int i=0; i< (int)title.length(); i++){
729  c[0]=title(i);
730  c[1]= '\0';
731  if ( c[0] == '\n' || c[0] == '\r') {
732  c[0]= ' ';
733  }
734  title2.append(c);
735  }
736  }
737  G4cout << title2 << G4endl;
738  }
739  G4cout << Comp->GetRange() << G4endl;
740  G4cout << parameterEntry << G4endl;
741  for( int par=0; par<parameterEntry; par++) {
742  prp = (G4UIparameter *)Comp->GetParameter(par);
743  G4cout << prp->GetParameterName() << G4endl;
744  G4cout << prp->GetParameterGuidance() << G4endl;
745  G4cout << prp->GetParameterType() << G4endl;
746  G4cout << prp->IsOmittable() << G4endl;
747  G4cout << prp->GetDefaultValue() << G4endl;
748  G4cout << prp->GetParameterRange() << G4endl;
749  G4cout << prp->GetParameterCandidates() << G4endl;
750  }
751  G4cout << "@@JParamEnd" << G4endl;
752 }
G4int GetGuidanceEntries() const
Definition: G4UIcommand.hh:135
G4String GetDefaultValue() const
G4String GetParameterRange() const
const G4String GetParameterGuidance() const
const G4String & GetGuidanceLine(G4int i) const
Definition: G4UIcommand.hh:137
G4bool IsOmittable() const
char GetParameterType() const
G4UIparameter * GetParameter(G4int i) const
Definition: G4UIcommand.hh:145
G4GLOB_DLL std::ostream G4cout
const G4String & GetRange() const
Definition: G4UIcommand.hh:133
G4String GetParameterName() const
G4String GetParameterCandidates() const
G4String & append(const G4String &)
const G4String & GetCommandPath() const
Definition: G4UIcommand.hh:139
G4int GetParameterEntries() const
Definition: G4UIcommand.hh:143
#define G4endl
Definition: G4ios.hh:61
subroutine title
Definition: hijing1.383.f:5981
Here is the call graph for this function:
Here is the caller graph for this function:

◆ SendATclParamProperty()

void G4UIGainServer::SendATclParamProperty ( G4UIcommand )
private

◆ SendCommandProperties()

void G4UIGainServer::SendCommandProperties ( G4UIcommandTree tree)
private

Definition at line 644 of file G4UIGainServer.cc.

644  {
646  if( tree == NULL ) {
647  G4cerr << "GetTree() returnes null." << G4endl;
648  return;
649  }
650  if (uiMode == java_mode){
651  G4cout << "@@JTreeBegin" << G4endl;
652  CodeGenJavaTree(tree, 0);
653  G4cout << "@@JTreeEnd" << G4endl;
654  CodeGenJavaParams(tree, 0);
655  }else{}
656 }
void CodeGenJavaTree(G4UIcommandTree *, int recursiveLevel)
void CodeGenJavaParams(G4UIcommandTree *, int recursiveLevel)
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
G4GLOB_DLL std::ostream G4cerr
Here is the call graph for this function:
Here is the caller graph for this function:

◆ SendDisableList()

void G4UIGainServer::SendDisableList ( G4UIcommandTree tree,
int  recursiveLevel 
)
private

Definition at line 755 of file G4UIGainServer.cc.

755  {
757  int treeEntry, commandEntry;
758  G4UIcommand * Comp;
759  treeEntry = tree->GetTreeEntry();
760  commandEntry = tree->GetCommandEntry();
761 
762  for(int com=0; com<commandEntry; com++) {
763  Comp = tree->GetCommand(com+1);
764  if( Comp->IsAvailable()==false ) {
765  G4cout << Comp->GetCommandPath()<<G4endl;
766  }
767  }
768  if( treeEntry == 0 ) return; // end recursion
769 
770  for( int i=0; i<treeEntry; i++) {
771  SendDisableList(tree->GetTree(i+1), level+1);
772  // be sure the function name is the same
773  }
774 }
G4bool IsAvailable()
Definition: G4UIcommand.cc:289
G4UIcommand * GetCommand(G4int i)
G4int GetCommandEntry() const
G4GLOB_DLL std::ostream G4cout
G4UIcommandTree * GetTree(G4int i)
const G4String & GetCommandPath() const
Definition: G4UIcommand.hh:139
#define G4endl
Definition: G4ios.hh:61
G4int GetTreeEntry() const
void SendDisableList(G4UIcommandTree *, int recursiveLevel)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ SendParameterProperties()

void G4UIGainServer::SendParameterProperties ( G4UIcommandTree tree)
private

Definition at line 659 of file G4UIGainServer.cc.

659  {
661  if( tree == NULL ) {
662  G4cerr << "GetTree() returnes null." << G4endl;
663  return;
664  }
665  if (uiMode == java_mode){
666  CodeGenJavaParams(tree, 0);
667  }else{ }
668 }
void CodeGenJavaParams(G4UIcommandTree *, int recursiveLevel)
#define G4endl
Definition: G4ios.hh:61
G4GLOB_DLL std::ostream G4cerr
Here is the call graph for this function:

◆ SessionStart()

G4UIsession * G4UIGainServer::SessionStart ( )
virtual

Implements G4VBasicShell.

Definition at line 94 of file G4UIGainServer.cc.

96 {
97  G4String newCommand;
98 
101 
102  iExit= TRUE;
103 
105  while(iExit){
106  newCommand= GetCommand();
107  ExecuteCommand(newCommand);
108  }
109  return NULL;
110 }
G4String GetStateString(G4ApplicationState aState) const
void WaitingConnection()
virtual void ExecuteCommand(const G4String &aCommand)
static G4StateManager * GetStateManager()
#define TRUE
Definition: globals.hh:55
G4String GetCommand()
G4ApplicationState GetCurrentState() const
G4String promptCharacter
Here is the call graph for this function:

◆ SessionTerminate()

void G4UIGainServer::SessionTerminate ( )

Definition at line 451 of file G4UIGainServer.cc.

451  {
453  G4cout<<"***** Terminal session end *****"<<G4endl;
454 }
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61

◆ SetUPServer()

bool G4UIGainServer::SetUPServer ( )
private

Definition at line 361 of file G4UIGainServer.cc.

361  {
363 
364  socketD[0] = socket(AF_INET,SOCK_STREAM,0);
365 
366  if(socketD[0]<0){
367  perror("server:socket");
368  return (false);
369  //exit(1);
370  }
371 
372  memset( (char *)&saddr,'\0',sizeof(saddr)) ;
373 
374  saddr.sin_family = AF_INET;
375  saddr.sin_addr.s_addr = INADDR_ANY;
376  saddr.sin_port = htons(port);
377  unlink(SOCK_NAME);
378 
379  if(bind(socketD[0] , (struct sockaddr *)&saddr , sizeof(saddr))<0){
380  perror("bind");
381  return (false);
382  //exit(1);
383  }
384  else{ G4cout<<"G4GainServer waiting at "<<port<<G4endl; }
385 
386  if(listen(socketD[0],1)<0){
387  perror("listen");
388  return (false);
389  //exit(1);
390  }
391 
392  return (true);
393 }
struct sockaddr_in saddr
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
#define SOCK_NAME
Here is the caller graph for this function:

◆ ShowCurrent()

void G4UIGainServer::ShowCurrent ( G4String  newCommand)
private

Definition at line 458 of file G4UIGainServer.cc.

458  {
460  G4String theCommand = GetFullPath(newCommand(1,newCommand.length()-1));
461  G4String curV = UI->GetCurrentValues(theCommand);
462  if( ! (curV.isNull()||curV(0)=='\0' ) ) {
463  if (uiMode == terminal_mode){
464  G4cout << "Current value(s) of the parameter(s) : " << curV << G4endl;
465  }else{
466  G4cout << "@@CurrentValue " << curV << G4endl;
467  }
468  } else if (uiMode == terminal_mode){
469  G4cout << "Current value is not available." << G4endl;
470  } else {
471  G4cout << "@@ErrResult \"Current value is not available.\"" << G4endl;
472  }
473 }
G4UImanager * UI
G4GLOB_DLL std::ostream G4cout
G4String GetCurrentValues(const char *aCommand)
Definition: G4UImanager.cc:170
#define G4endl
Definition: G4ios.hh:61
G4String GetFullPath(G4String)
G4bool isNull() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ TerminalHelp()

void G4UIGainServer::TerminalHelp ( G4String  newCommand)
private

Definition at line 532 of file G4UIGainServer.cc.

532  {
534  G4UIcommandTree* treeTop = UI->GetTree();
535  str_size i = newCommand.index(" ");
536 
537  if(i!=std::string::npos){
538  G4String newValue = newCommand(i+1,newCommand.length()-(i+1));
539  newValue.strip(G4String::both);
540  if(newValue(0)!='/'){
541  newValue.prepend(prefix);
542  }
543  G4UIcommand* theCommand = treeTop->FindPath(newValue);
544  if(theCommand !=NULL){
545  theCommand->List();
546  return;
547  }
548  else{
549  G4cout<<"Command<" << newValue << "is not found."<<G4endl;
550  return;
551  }
552  }
553 
554  G4UIcommandTree* floor[10];
555  floor[0] = treeTop;
556  int iFloor = 0;
557  unsigned prefixIndex = 1;
558  while(prefixIndex<prefix.length()-1){
559  int ii = prefix.index("/",prefixIndex);
560  floor[iFloor+1]=
561  floor[iFloor]->GetTree(G4String(prefix(0,ii+1)));
562  prefixIndex = ii+1;
563  iFloor++;
564  }
565  floor[iFloor]->ListCurrentWithNum();
566  while(1){
567  int j;
568  G4cout<<G4endl <<"Type the number (0:end, -n:n level back) :"<<std::flush;
569  G4cin >> j;
570  if(!G4cin.good()){
571  G4cin.clear();
572  G4cin.ignore(30,'\n');
573  G4cout<<G4endl <<"Not a number,once more"<<G4endl; continue;
574  }
575  else if(j<0){
576  iFloor += j;
577  if(iFloor <0) iFloor =0;
578  floor[iFloor]->ListCurrentWithNum(); continue;
579  }
580  else if(j==0){break;}
581  else if(j>0){
582  int n_tree = floor[iFloor]->GetTreeEntry();
583  if(j>n_tree){
584  if(j<=n_tree+floor[iFloor]->GetCommandEntry()){
585  floor[iFloor]->GetCommand(j-n_tree)->List();
586  }
587  }
588  else{
589  floor[iFloor+1] = floor[iFloor]->GetTree(j);
590  iFloor++;
591  floor[iFloor]->ListCurrentWithNum();
592  }
593  }
594  }
595  G4cout<<"Exit from Help."<<G4endl <<G4endl;
596  G4cout<<G4endl;
597  char temp[100];
598  G4cin.getline(temp,100);
599 }
G4String strip(G4int strip_Type=trailing, char c=' ')
G4UIcommand * GetCommand(G4int i)
std::string::size_type str_size
str_size index(const char *, G4int pos=0) const
G4UImanager * UI
G4String & prepend(const char *)
#define G4cin
Definition: G4ios.hh:60
G4GLOB_DLL std::ostream G4cout
G4UIcommandTree * GetTree(G4int i)
G4UIcommandTree * GetTree() const
Definition: G4UImanager.hh:206
G4UIcommand * FindPath(const char *commandPath) const
#define G4endl
Definition: G4ios.hh:61
G4int GetTreeEntry() const
virtual void List()
Definition: G4UIcommand.cc:348
void ListCurrentWithNum() const
Here is the call graph for this function:
Here is the caller graph for this function:

◆ UpdateParamVal()

void G4UIGainServer::UpdateParamVal ( void  )
private

Definition at line 886 of file G4UIGainServer.cc.

886  {
888  // call NotifyParameterUpdate() if the value of each
889  // command/parameter is updated.
890  // assuming the command structure is not changed.
891  int pEntry= previousTreeParams.size();
892  int nEntry= newTreeParams.size();
893  int i;
894  G4UIcommand* Comp;
895  if (pEntry != nEntry) return;
896  for( i=0; i<nEntry; i++) {
897  if( previousTreeParams[i] != newTreeParams[i]){
898  Comp = newTreePCP[i];
899  G4cout << Comp->GetCommandPath()
900  << " command is updated." <<G4endl;
901  NotifyParameterUpdate(Comp);
902  }
903  }
904 }
std::vector< G4UIcommand * > newTreePCP
void NotifyParameterUpdate(G4UIcommand *)
G4GLOB_DLL std::ostream G4cout
std::vector< G4String > previousTreeParams
const G4String & GetCommandPath() const
Definition: G4UIcommand.hh:139
#define G4endl
Definition: G4ios.hh:61
std::vector< G4String > newTreeParams
Here is the call graph for this function:
Here is the caller graph for this function:

◆ UpdateState()

void G4UIGainServer::UpdateState ( void  )
private

Definition at line 781 of file G4UIGainServer.cc.

783 {
784  static G4ThreadLocal G4ApplicationState *previousState_G4MT_TLS_ = 0 ; if (!previousState_G4MT_TLS_) {previousState_G4MT_TLS_ = new G4ApplicationState ; *previousState_G4MT_TLS_= G4State_PreInit ; } G4ApplicationState &previousState = *previousState_G4MT_TLS_;
785  G4ApplicationState newState;
787  newState = statM->GetCurrentState();
788  if( newState != previousState )
789  {
791  previousState = newState;
792  }
793 }
#define G4ThreadLocal
Definition: tls.hh:89
static G4StateManager * GetStateManager()
void NotifyStateChange(void)
G4ApplicationState GetCurrentState() const
G4ApplicationState
Here is the call graph for this function:
Here is the caller graph for this function:

◆ WaitingConnection()

void G4UIGainServer::WaitingConnection ( )
private

Definition at line 396 of file G4UIGainServer.cc.

396  {
398  len = sizeof(caddr);
399 
400  for(int i=1;i<=2;i++){
401 #if defined __APPLE__ && (__GNUC__<4)
402  if((socketD[i] = accept(socketD[0], (struct sockaddr *)&caddr,(int *)&len))<0){
403 #else
404  if((socketD[i] = accept(socketD[0], (struct sockaddr *)&caddr,(socklen_t *)&len))<0){
405 #endif
406  G4cerr<<"accept:"<<i<<G4endl;
407  //exit(1);
408  G4Exception("G4UIGainServer::WaitingConnection()",
409  "UI0004",
411  "Invalid Socket. Cannot establish connection");
412  }
413  }
414  close(socketD[0]);
415 }
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
Definition: G4Exception.cc:41
in close()
#define G4endl
Definition: G4ios.hh:61
struct sockaddr_in caddr
G4GLOB_DLL std::ostream G4cerr
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ buf

char G4UIGainServer::buf[1024]
private

Definition at line 87 of file G4UIGainServer.hh.

◆ caddr

struct sockaddr_in G4UIGainServer::caddr
private

Definition at line 84 of file G4UIGainServer.hh.

◆ iCont

G4bool G4UIGainServer::iCont
private

Definition at line 78 of file G4UIGainServer.hh.

◆ iExit

G4bool G4UIGainServer::iExit
private

Definition at line 77 of file G4UIGainServer.hh.

◆ JVersion

G4String G4UIGainServer::JVersion
private

Definition at line 70 of file G4UIGainServer.hh.

◆ len

int G4UIGainServer::len
private

Definition at line 85 of file G4UIGainServer.hh.

◆ newTreeCommands

std::vector<G4String> G4UIGainServer::newTreeCommands
private

Definition at line 94 of file G4UIGainServer.hh.

◆ newTreeParams

std::vector<G4String> G4UIGainServer::newTreeParams
private

Definition at line 96 of file G4UIGainServer.hh.

◆ newTreePCP

std::vector<G4UIcommand*> G4UIGainServer::newTreePCP
private

Definition at line 98 of file G4UIGainServer.hh.

◆ port

int G4UIGainServer::port
private

Definition at line 82 of file G4UIGainServer.hh.

◆ prefix

G4String G4UIGainServer::prefix
private

Definition at line 66 of file G4UIGainServer.hh.

◆ previousTreeCommands

std::vector<G4String> G4UIGainServer::previousTreeCommands
private

Definition at line 93 of file G4UIGainServer.hh.

◆ previousTreeParams

std::vector<G4String> G4UIGainServer::previousTreeParams
private

Definition at line 95 of file G4UIGainServer.hh.

◆ previousTreePCP

std::vector<G4UIcommand*> G4UIGainServer::previousTreePCP
private

Definition at line 97 of file G4UIGainServer.hh.

◆ promptCharacter

G4String G4UIGainServer::promptCharacter
private

Definition at line 67 of file G4UIGainServer.hh.

◆ ret

int G4UIGainServer::ret
private

Definition at line 86 of file G4UIGainServer.hh.

◆ saddr

struct sockaddr_in G4UIGainServer::saddr
private

Definition at line 83 of file G4UIGainServer.hh.

◆ socketD

int G4UIGainServer::socketD[3]
private

Definition at line 81 of file G4UIGainServer.hh.

◆ TVersion

G4String G4UIGainServer::TVersion
private

Definition at line 71 of file G4UIGainServer.hh.

◆ UI

G4UImanager* G4UIGainServer::UI
private

Definition at line 68 of file G4UIGainServer.hh.

◆ uiMode

UImode G4UIGainServer::uiMode
private

Definition at line 69 of file G4UIGainServer.hh.


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