Geant4  10.01.p01
G4P2Messenger.cc
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // $Id$
27 
28 // Author: Ivana Hrivnacova, 24/07/2014 (ivana@ipno.in2p3.fr)
29 
30 #include "G4P2Messenger.hh"
31 #include "G4VAnalysisManager.hh"
32 #include "G4AnalysisUtilities.hh"
33 
34 #include "G4UIdirectory.hh"
35 #include "G4UIcommand.hh"
36 #include "G4UIparameter.hh"
37 
38 #include <iostream>
39 
40 using namespace G4Analysis;
41 
42 namespace {
43 
44 void Exception(G4UIcommand* command, G4int nofParameters)
45 {
46  G4ExceptionDescription description;
47  description
48  << "Got wrong number of \"" << command->GetCommandName()
49  << "\" parameters: " << nofParameters
50  << " instead of " << command->GetParameterEntries()
51  << " expected" << G4endl;
52  G4Exception("G4P2Messenger::SetNewValue",
53  "Analysis_W013", JustWarning, description);
54 }
55 
56 }
57 
58 
59 //_____________________________________________________________________________
61  : G4UImessenger(),
62  fManager(manager),
63  fP2Dir(0),
64  fCreateP2Cmd(0),
65  fSetP2Cmd(0),
66  fSetP2TitleCmd(0),
67  fSetP2XAxisCmd(0),
68  fSetP2YAxisCmd(0)
69 {
70  fP2Dir = new G4UIdirectory("/analysis/p2/");
71  fP2Dir->SetGuidance("2D profiles control");
72 
73  CreateP2Cmd();
74  SetP2Cmd();
75 
76  SetP2TitleCmd();
77  SetP2XAxisCmd();
78  SetP2YAxisCmd();
79  SetP2ZAxisCmd();
80 }
81 
82 //_____________________________________________________________________________
84 {
85  delete fCreateP2Cmd;
86  delete fSetP2Cmd;
87  delete fSetP2TitleCmd;
88  delete fSetP2XAxisCmd;
89  delete fSetP2YAxisCmd;
90  delete fSetP2ZAxisCmd;
91  delete fP2Dir;
92 }
93 
94 //
95 // private functions
96 //
97 
98 //_____________________________________________________________________________
100 {
101  G4UIparameter* p2Name = new G4UIparameter("name", 's', false);
102  p2Name->SetGuidance("Profile name (label)");
103 
104  G4UIparameter* p2Title = new G4UIparameter("title", 's', false);
105  p2Title->SetGuidance("Profile title");
106 
107  G4UIparameter* p2xNbins0 = new G4UIparameter("xnbins0", 'i', true);
108  p2xNbins0->SetGuidance("Number of x-bins (default = 100)");
109  p2xNbins0->SetGuidance("Can be reset with /analysis/p2/set command");
110  p2xNbins0->SetDefaultValue(100);
111 
112  G4UIparameter* p2xValMin0 = new G4UIparameter("xvalMin0", 'd', true);
113  p2xValMin0->SetGuidance("Minimum x-value, expressed in unit (default = 0.)");
114  p2xValMin0->SetGuidance("Can be reset with /analysis/p2/set command");
115  p2xValMin0->SetDefaultValue(0.);
116 
117  G4UIparameter* p2xValMax0 = new G4UIparameter("xvalMax0", 'd', true);
118  p2xValMax0->SetGuidance("Maximum x-value, expressed in unit (default = 1.)");
119  p2xValMax0->SetGuidance("Can be reset with /analysis/p2/set command");
120  p2xValMax0->SetDefaultValue(1.);
121 
122  G4UIparameter* p2xValUnit0 = new G4UIparameter("xvalUnit0", 's', true);
123  p2xValUnit0->SetGuidance("The unit applied to filled x-values and xvalMin0, xvalMax0");
124  p2xValUnit0->SetDefaultValue("none");
125 
126  G4UIparameter* p2xValFcn0 = new G4UIparameter("xvalFcn0", 's', true);
127  G4String fcnxGuidance = "The function applied to filled x-values (log, log10, exp, none).";
128  p2xValFcn0->SetGuidance(fcnxGuidance);
129  p2xValFcn0->SetParameterCandidates("log log10 exp none");
130  p2xValFcn0->SetDefaultValue("none");
131 
132  G4UIparameter* p2xValBinScheme0 = new G4UIparameter("xvalBinScheme0", 's', true);
133  G4String binSchemeGuidance = "The binning scheme (linear, log).";
134  p2xValBinScheme0->SetParameterCandidates("linear log");
135  p2xValBinScheme0->SetGuidance(binSchemeGuidance);
136  p2xValBinScheme0->SetDefaultValue("linear");
137 
138  G4UIparameter* p2yNbins0 = new G4UIparameter("ynbins0", 'i', true);
139  p2yNbins0->SetGuidance("Number of y-bins (default = 100)");
140  p2yNbins0->SetGuidance("Can be reset with /analysis/p2/set command");
141  p2yNbins0->SetDefaultValue(100);
142 
143  G4UIparameter* p2yValMin0 = new G4UIparameter("yvalMin0", 'd', true);
144  p2yValMin0->SetGuidance("Minimum y-value, expressed in unit (default = 0.)");
145  p2yValMin0->SetGuidance("Can be reset with /analysis/p2/set command");
146  p2yValMin0->SetDefaultValue(0.);
147 
148  G4UIparameter* p2yValMax0 = new G4UIparameter("yvalMax0", 'd', true);
149  p2yValMax0->SetGuidance("Maximum y-value, expressed in unit (default = 1.)");
150  p2yValMax0->SetGuidance("Can be reset with /analysis/p2/set command");
151  p2yValMax0->SetDefaultValue(1.);
152 
153  G4UIparameter* p2yValUnit0 = new G4UIparameter("yvalUnit0", 's', true);
154  p2yValUnit0->SetGuidance("The unit applied to filled y-values and yvalMin0, yvalMax0");
155  p2yValUnit0->SetDefaultValue("none");
156 
157  G4UIparameter* p2yValFcn0 = new G4UIparameter("yvalFcn0", 's', true);
158  G4String fcnyGuidance = "The function applied to filled y-values (log, log10, exp, none).";
159  p2yValFcn0->SetGuidance(fcnyGuidance);
160  p2yValFcn0->SetParameterCandidates("log log10 exp none");
161  p2yValFcn0->SetDefaultValue("none");
162 
163  G4UIparameter* p2yValBinScheme0 = new G4UIparameter("yvalBinScheme0", 's', true);
164  p2yValBinScheme0->SetParameterCandidates("linear log");
165  p2yValBinScheme0->SetGuidance(binSchemeGuidance);
166  p2yValBinScheme0->SetDefaultValue("linear");
167 
168  G4UIparameter* p2zValMin0 = new G4UIparameter("zvalMin0", 'd', true);
169  p2zValMin0->SetGuidance("Minimum z-value, expressed in unit (default = 0.)");
170  p2zValMin0->SetGuidance("Can be reset with /analysis/p2/set command");
171  p2zValMin0->SetDefaultValue(0.);
172 
173  G4UIparameter* p2zValMax0 = new G4UIparameter("zvalMax0", 'd', true);
174  p2zValMax0->SetGuidance("Maximum z-value, expressed in unit (default = 1.)");
175  p2zValMax0->SetGuidance("Can be reset with /analysis/p2/set command");
176  p2zValMax0->SetDefaultValue(1.);
177 
178  G4UIparameter* p2zValUnit0 = new G4UIparameter("zvalUnit0", 's', true);
179  p2zValUnit0->SetGuidance("The unit applied to filled z-values and zvalMin0, zvalMax0");
180  p2zValUnit0->SetDefaultValue("none");
181 
182  G4UIparameter* p2zValFcn0 = new G4UIparameter("zvalFcn0", 's', true);
183  G4String fcnzGuidance = "The function applied to filled z-values (log, log10, exp, none).";
184  p2zValFcn0->SetGuidance(fcnzGuidance);
185  p2zValFcn0->SetParameterCandidates("log log10 exp none");
186  p2zValFcn0->SetDefaultValue("none");
187 
188  fCreateP2Cmd = new G4UIcommand("/analysis/p2/create", this);
189  fCreateP2Cmd->SetGuidance("Create 2D profile");
190  fCreateP2Cmd->SetParameter(p2Name);
191  fCreateP2Cmd->SetParameter(p2Title);
192  fCreateP2Cmd->SetParameter(p2xNbins0);
193  fCreateP2Cmd->SetParameter(p2xValMin0);
194  fCreateP2Cmd->SetParameter(p2xValMax0);
195  fCreateP2Cmd->SetParameter(p2xValUnit0);
196  fCreateP2Cmd->SetParameter(p2xValFcn0);
197  fCreateP2Cmd->SetParameter(p2xValBinScheme0);
198  fCreateP2Cmd->SetParameter(p2yNbins0);
199  fCreateP2Cmd->SetParameter(p2yValMin0);
200  fCreateP2Cmd->SetParameter(p2yValMax0);
201  fCreateP2Cmd->SetParameter(p2yValUnit0);
202  fCreateP2Cmd->SetParameter(p2yValFcn0);
203  fCreateP2Cmd->SetParameter(p2yValBinScheme0);
204  fCreateP2Cmd->SetParameter(p2zValMin0);
205  fCreateP2Cmd->SetParameter(p2zValMax0);
206  fCreateP2Cmd->SetParameter(p2zValUnit0);
207  fCreateP2Cmd->SetParameter(p2zValFcn0);
209 }
210 
211 
212 //_____________________________________________________________________________
214 {
215  G4UIparameter* p2Id = new G4UIparameter("id", 'i', false);
216  p2Id->SetGuidance("Profile id");
217  p2Id->SetParameterRange("id>=0");
218 
219  G4UIparameter* p2xNbins = new G4UIparameter("xnbins", 'i', false);
220  p2xNbins->SetGuidance("Number of x-bins");
221 
222  G4UIparameter* p2xValMin = new G4UIparameter("xvalMin", 'd', false);
223  p2xValMin->SetGuidance("Minimum x-value, expressed in unit");
224 
225  G4UIparameter* p2xValMax = new G4UIparameter("xvalMax", 'd', false);
226  p2xValMax->SetGuidance("Maximum x-value, expressed in unit");
227 
228  G4UIparameter* p2xValUnit = new G4UIparameter("xvalUnit", 's', false);
229  p2xValUnit->SetGuidance("The unit applied to filled x-values and xvalMin0, xvalMax0");
230  p2xValUnit->SetDefaultValue("none");
231 
232  G4UIparameter* p2xValFcn = new G4UIparameter("xvalFcn", 's', false);
233  p2xValFcn->SetParameterCandidates("log log10 exp none");
234  G4String fcnxGuidance = "The function applied to filled x-values (log, log10, exp, none).";
235  p2xValFcn->SetGuidance(fcnxGuidance);
236  p2xValFcn->SetDefaultValue("none");
237 
238  G4UIparameter* p2xValBinScheme = new G4UIparameter("xvalBinScheme", 's', true);
239  G4String binSchemeGuidance = "The binning scheme (linear, log).";
240  p2xValBinScheme->SetParameterCandidates("linear log");
241  p2xValBinScheme->SetGuidance(binSchemeGuidance);
242  p2xValBinScheme->SetDefaultValue("linear");
243 
244  G4UIparameter* p2yNbins = new G4UIparameter("nybins", 'i', false);
245  p2yNbins->SetGuidance("Number of y-bins");
246 
247  G4UIparameter* p2yValMin = new G4UIparameter("yvalMin", 'd', false);
248  p2yValMin->SetGuidance("Minimum y-value, expressed in unit");
249 
250  G4UIparameter* p2yValMax = new G4UIparameter("yvalMax", 'd', false);
251  p2yValMax->SetGuidance("Maximum y-value, expressed in unit");
252 
253  G4UIparameter* p2yValUnit = new G4UIparameter("yvalUnit", 's', true);
254  p2yValUnit->SetGuidance("The unit applied to filled y-values and yvalMin0, yvalMax0");
255  p2yValUnit->SetDefaultValue("none");
256 
257  G4UIparameter* p2yValFcn = new G4UIparameter("yvalFcn", 's', false);
258  p2yValFcn->SetParameterCandidates("log log10 exp none");
259  G4String fcnyGuidance = "The function applied to filled y-values (log, log10, exp, none).";
260  p2yValFcn->SetGuidance(fcnyGuidance);
261  p2yValFcn->SetDefaultValue("none");
262 
263  G4UIparameter* p2yValBinScheme = new G4UIparameter("yvalBinScheme", 's', true);
264  p2yValBinScheme->SetParameterCandidates("linear log");
265  p2yValBinScheme->SetGuidance(binSchemeGuidance);
266  p2yValBinScheme->SetDefaultValue("linear");
267 
268  G4UIparameter* p2zValMin = new G4UIparameter("zvalMin", 'd', false);
269  p2zValMin->SetGuidance("Minimum z-value, expressed in unit");
270 
271  G4UIparameter* p2zValMax = new G4UIparameter("zvalMax", 'd', false);
272  p2zValMax->SetGuidance("Maximum z-value, expressed in unit");
273 
274  G4UIparameter* p2zValUnit = new G4UIparameter("zvalUnit", 's', true);
275  p2zValUnit->SetGuidance("The unit applied to filled z-values and zvalMin0, zvalMax0");
276  p2zValUnit->SetDefaultValue("none");
277 
278  G4UIparameter* p2zValFcn = new G4UIparameter("zvalFcn", 's', false);
279  p2zValFcn->SetParameterCandidates("log log10 exp none");
280  G4String fcnzGuidance = "The function applied to filled z-values (log, log10, exp, none).";
281  p2zValFcn->SetGuidance(fcnzGuidance);
282  p2zValFcn->SetDefaultValue("none");
283 
284  fSetP2Cmd = new G4UIcommand("/analysis/p2/set", this);
285  fSetP2Cmd->SetGuidance("Set parameters for the 2D profile of #Id :");
286  fSetP2Cmd->SetGuidance(" nxbins; xvalMin; xvalMax; xunit; xbinScheme");
287  fSetP2Cmd->SetGuidance(" nybins; yvalMin; yvalMax; yunit; ybinScheme");
288  fSetP2Cmd->SetGuidance(" zvalMin; zvalMax; zunit; zfunction");
289  fSetP2Cmd->SetParameter(p2Id);
290  fSetP2Cmd->SetParameter(p2xNbins);
291  fSetP2Cmd->SetParameter(p2xValMin);
292  fSetP2Cmd->SetParameter(p2xValMax);
293  fSetP2Cmd->SetParameter(p2xValUnit);
294  fSetP2Cmd->SetParameter(p2xValFcn);
295  fSetP2Cmd->SetParameter(p2xValBinScheme);
296  fSetP2Cmd->SetParameter(p2yNbins);
297  fSetP2Cmd->SetParameter(p2yValMin);
298  fSetP2Cmd->SetParameter(p2yValMax);
299  fSetP2Cmd->SetParameter(p2yValUnit);
300  fSetP2Cmd->SetParameter(p2yValFcn);
301  fSetP2Cmd->SetParameter(p2yValBinScheme);
302  fSetP2Cmd->SetParameter(p2zValMin);
303  fSetP2Cmd->SetParameter(p2zValMax);
304  fSetP2Cmd->SetParameter(p2zValUnit);
305  fSetP2Cmd->SetParameter(p2zValFcn);
307 }
308 
309 //_____________________________________________________________________________
311 {
312  G4UIparameter* p2Id = new G4UIparameter("idTitle", 'i', false);
313  p2Id->SetGuidance("Profile id");
314  p2Id->SetParameterRange("idTitle>=0");
315 
316  G4UIparameter* p2Title = new G4UIparameter("p2Title", 's', true);
317  p2Title->SetGuidance("Profile title");
318  p2Title->SetDefaultValue("none");
319 
320  fSetP2TitleCmd = new G4UIcommand("/analysis/p2/setTitle", this);
321  fSetP2TitleCmd->SetGuidance("Set title for the 2D profile of #Id");
323  fSetP2TitleCmd->SetParameter(p2Title);
325 }
326 
327 //_____________________________________________________________________________
329 {
330  G4UIparameter* p2Id = new G4UIparameter("idXaxis", 'i', false);
331  p2Id->SetGuidance("Profile id");
332  p2Id->SetParameterRange("idXaxis>=0");
333 
334  G4UIparameter* p2XAxis = new G4UIparameter("p2Xaxis", 's', true);
335  p2XAxis->SetGuidance("Profile x-axis title");
336  p2XAxis->SetDefaultValue("none");
337 
338  fSetP2XAxisCmd = new G4UIcommand("/analysis/p2/setXaxis", this);
339  fSetP2XAxisCmd->SetGuidance("Set x-axis title for the 2D profile of #Id");
341  fSetP2XAxisCmd->SetParameter(p2XAxis);
343 }
344 
345 //_____________________________________________________________________________
347 {
348  G4UIparameter* p2Id = new G4UIparameter("idYaxis", 'i', false);
349  p2Id->SetGuidance("Profile id");
350  p2Id->SetParameterRange("idYaxis>=0");
351 
352  G4UIparameter* p2YAxis = new G4UIparameter("p2Yaxis", 's', true);
353  p2YAxis->SetGuidance("Profile y-axis title");
354  p2YAxis->SetDefaultValue("none");
355 
356  fSetP2YAxisCmd = new G4UIcommand("/analysis/p2/setYaxis", this);
357  fSetP2YAxisCmd->SetGuidance("Set y-axis title for the 2D profile of #Id");
359  fSetP2YAxisCmd->SetParameter(p2YAxis);
361 }
362 
363 //_____________________________________________________________________________
365 {
366  G4UIparameter* p2Id = new G4UIparameter("idZaxis", 'i', false);
367  p2Id->SetGuidance("Profile id");
368  p2Id->SetParameterRange("idZaxis>=0");
369 
370  G4UIparameter* p2ZAxis = new G4UIparameter("p2Zaxis", 's', true);
371  p2ZAxis->SetGuidance("Profile z-axis title");
372  p2ZAxis->SetDefaultValue("none");
373 
374  fSetP2ZAxisCmd = new G4UIcommand("/analysis/p2/setZaxis", this);
376  fSetP2ZAxisCmd->SetParameter(p2ZAxis);
378 }
379 
380 //
381 // public functions
382 //
383 
384 //_____________________________________________________________________________
386 {
387  // tokenize parameters in a vector
388  std::vector<G4String> parameters;
389  G4Analysis::Tokenize(newValues, parameters);
390  // check consistency
391  if ( G4int(parameters.size()) != command->GetParameterEntries() ) {
392  // Should never happen but let's check anyway for consistency
393  Exception(command, parameters.size());
394  return;
395  }
396 
397  if ( command == fCreateP2Cmd ) {
398  G4int counter = 0;
399  G4String name = parameters[counter++];
400  G4String title = parameters[counter++];
401  G4int xnbins = G4UIcommand::ConvertToInt(parameters[counter++]);
402  G4double xvmin = G4UIcommand::ConvertToDouble(parameters[counter++]);
403  G4double xvmax = G4UIcommand::ConvertToDouble(parameters[counter++]); ;
404  G4String xsunit = parameters[counter++];
405  G4String xsfcn = parameters[counter++];
406  G4String xsbinScheme = parameters[counter++];
407  G4double xunit = GetUnitValue(xsunit);
408  G4int ynbins = G4UIcommand::ConvertToInt(parameters[counter++]);
409  G4double yvmin = G4UIcommand::ConvertToDouble(parameters[counter++]);
410  G4double yvmax = G4UIcommand::ConvertToDouble(parameters[counter++]); ;
411  G4String ysunit = parameters[counter++];
412  G4String ysfcn = parameters[counter++];
413  G4String ysbinScheme = parameters[counter++];
414  G4double yunit = GetUnitValue(ysunit);
415  G4double zvmin = G4UIcommand::ConvertToDouble(parameters[counter++]);
416  G4double zvmax = G4UIcommand::ConvertToDouble(parameters[counter++]); ;
417  G4String zsunit = parameters[counter++];
418  G4String zsfcn = parameters[counter++];
419  G4double zunit = GetUnitValue(zsunit);
420  fManager->CreateP2(name, title,
421  xnbins, xvmin*xunit, xvmax*xunit,
422  ynbins, yvmin*yunit, yvmax*yunit,
423  zvmin*zunit, zvmax*zunit,
424  xsunit, ysunit, zsunit, xsfcn, ysfcn, zsfcn,
425  xsbinScheme, ysbinScheme);
426  }
427  else if ( command == fSetP2Cmd ) {
428  G4int counter = 0;
429  G4int id = G4UIcommand::ConvertToInt(parameters[counter++]);
430  G4int xnbins = G4UIcommand::ConvertToInt(parameters[counter++]);
431  G4double xvmin = G4UIcommand::ConvertToDouble(parameters[counter++]);
432  G4double xvmax = G4UIcommand::ConvertToDouble(parameters[counter++]); ;
433  G4String xsunit = parameters[counter++];
434  G4String xsfcn = parameters[counter++];
435  G4String xsbinScheme = parameters[counter++];
436  G4double xunit = GetUnitValue(xsunit);
437  G4int ynbins = G4UIcommand::ConvertToInt(parameters[counter++]);
438  G4double yvmin = G4UIcommand::ConvertToDouble(parameters[counter++]);
439  G4double yvmax = G4UIcommand::ConvertToDouble(parameters[counter++]); ;
440  G4String ysunit = parameters[counter++];
441  G4String ysfcn = parameters[counter++];
442  G4String ysbinScheme = parameters[counter++];
443  G4double yunit = GetUnitValue(ysunit);
444  G4double zvmin = G4UIcommand::ConvertToDouble(parameters[counter++]);
445  G4double zvmax = G4UIcommand::ConvertToDouble(parameters[counter++]); ;
446  G4String zsunit = parameters[counter++];
447  G4String zsfcn = parameters[counter++];
448  G4double zunit = GetUnitValue(zsunit);
449  fManager->SetP2(id,
450  xnbins, xvmin*xunit, xvmax*xunit,
451  ynbins, yvmin*yunit, yvmax*yunit,
452  zvmin*zunit, zvmax*zunit,
453  xsunit, ysunit, zsunit, xsfcn, ysfcn, zsfcn,
454  xsbinScheme, ysbinScheme);
455  }
456  else if ( command == fSetP2TitleCmd ) {
457  G4int counter = 0;
458  G4int id = G4UIcommand::ConvertToInt(parameters[counter++]);
459  G4String title = parameters[counter++];
460  fManager->SetP2Title(id, title);
461  }
462  else if ( command == fSetP2XAxisCmd ) {
463  G4int counter = 0;
464  G4int id = G4UIcommand::ConvertToInt(parameters[counter++]);
465  G4String xaxis = parameters[counter++];
466  fManager->SetP2XAxisTitle(id, xaxis);
467  }
468  else if ( command == fSetP2YAxisCmd ) {
469  G4int counter = 0;
470  G4int id = G4UIcommand::ConvertToInt(parameters[counter++]);
471  G4String yaxis = parameters[counter++];
472  fManager->SetP2YAxisTitle(id, yaxis);
473  }
474  else if ( command == fSetP2ZAxisCmd ) {
475  G4int counter = 0;
476  G4int id = G4UIcommand::ConvertToInt(parameters[counter++]);
477  G4String zaxis = parameters[counter++];
478  fManager->SetP2ZAxisTitle(id, zaxis);
479  }
480 }
G4UIcommand * fSetP2Cmd
void SetParameter(G4UIparameter *const newParameter)
Definition: G4UIcommand.hh:152
G4bool SetP2ZAxisTitle(G4int id, const G4String &title)
std::ostringstream G4ExceptionDescription
Definition: globals.hh:76
void SetParameterRange(const char *theRange)
void SetParameterCandidates(const char *theString)
G4String name
Definition: TRTMaterials.hh:40
void SetDefaultValue(const char *theDefaultValue)
G4bool SetP2Title(G4int id, const G4String &title)
G4UIcommand * fSetP2TitleCmd
int G4int
Definition: G4Types.hh:78
virtual ~G4P2Messenger()
G4UIcommand * fCreateP2Cmd
G4UIcommand * fSetP2XAxisCmd
G4bool SetP2XAxisTitle(G4int id, const G4String &title)
virtual void SetNewValue(G4UIcommand *command, G4String value)
void SetGuidance(const char *aGuidance)
Definition: G4UIcommand.hh:161
static G4double ConvertToDouble(const char *st)
Definition: G4UIcommand.cc:443
G4P2Messenger(G4VAnalysisManager *manager)
void AvailableForStates(G4ApplicationState s1)
Definition: G4UIcommand.cc:239
G4double GetUnitValue(const G4String &unit)
static G4int ConvertToInt(const char *st)
Definition: G4UIcommand.cc:435
void SetP2XAxisCmd()
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
Definition: G4Exception.cc:41
G4bool SetP2(G4int id, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, G4double zmin=0, G4double zmax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear")
const G4String & GetCommandName() const
Definition: G4UIcommand.hh:141
void Exception(const char *originOfException, const char *exceptionCode, UExceptionSeverity severity, int level, const char *description)
Definition: UUtils.cc:122
G4bool SetP2YAxisTitle(G4int id, const G4String &title)
G4VAnalysisManager * fManager
Associated class.
void Tokenize(const G4String &line, std::vector< G4String > &tokens)
G4UIdirectory * fP2Dir
G4int CreateP2(const G4String &name, const G4String &title, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, G4double zmin=0, G4double zmax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear")
G4UIcommand * fSetP2YAxisCmd
void CreateP2Cmd()
#define G4endl
Definition: G4ios.hh:61
void SetP2TitleCmd()
double G4double
Definition: G4Types.hh:76
void SetGuidance(const char *theGuidance)
G4int GetParameterEntries() const
Definition: G4UIcommand.hh:143
G4UIcommand * fSetP2ZAxisCmd
void SetP2YAxisCmd()
void SetP2ZAxisCmd()