Import Geant4 5.1.0 source tree
This commit is contained in:
@@ -0,0 +1,74 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: ExN06PrimaryGeneratorMessenger.cc,v 1.1 2003/01/23 15:34:32 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-05-01 $
|
||||
//
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "ExN06PrimaryGeneratorMessenger.hh"
|
||||
|
||||
#include "ExN06PrimaryGeneratorAction.hh"
|
||||
#include "G4UIdirectory.hh"
|
||||
#include "G4UIcmdWithADoubleAndUnit.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
ExN06PrimaryGeneratorMessenger::ExN06PrimaryGeneratorMessenger(
|
||||
ExN06PrimaryGeneratorAction* ExN06Gun)
|
||||
:ExN06Action(ExN06Gun)
|
||||
{
|
||||
gunDir = new G4UIdirectory("/N06/gun/");
|
||||
gunDir->SetGuidance("PrimaryGenerator control");
|
||||
|
||||
polarCmd = new G4UIcmdWithADoubleAndUnit("/N06/gun/optPhotonPolar",this);
|
||||
polarCmd->SetGuidance("Set linear polarization");
|
||||
polarCmd->SetGuidance(" angle w.r.t. (k,n) plane");
|
||||
polarCmd->SetParameterName("angle",true);
|
||||
polarCmd->SetUnitCategory("Angle");
|
||||
polarCmd->SetDefaultValue(0.);
|
||||
polarCmd->AvailableForStates(G4State_Idle);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
ExN06PrimaryGeneratorMessenger::~ExN06PrimaryGeneratorMessenger()
|
||||
{
|
||||
delete polarCmd;
|
||||
delete gunDir;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void ExN06PrimaryGeneratorMessenger::SetNewValue(
|
||||
G4UIcommand* command, G4String newValue)
|
||||
{
|
||||
if( command == polarCmd )
|
||||
{ ExN06Action->SetOptPhotonPolar(polarCmd->GetNewDoubleValue(newValue));}
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
Reference in New Issue
Block a user