72 G4cout<<
"G4TrajectoryDrawByCharge drawer named "<<
Name();
73 G4cout<<
", drawing trajectory with charge, "<<charge<<
G4endl;
84 ostr<<
"G4TrajectoryDrawByCharge model "<<
Name() <<
" colour scheme: "<<std::endl;
86 ostr<<
"Default configuration:"<<
G4endl;
93 fMap.
Set(charge, colour);
99 fMap[charge] = colour;
107 if (!ConvertToCharge(charge, myCharge)) {
109 ed <<
"Invalid charge "<<charge;
111 (
"G4TrajectoryDrawByCharge::Set(const G4int& charge, const G4String& colour)",
"modeling0121",
JustWarning, ed);
115 return Set(myCharge, colour);
123 if (!ConvertToCharge(charge, myCharge)) {
125 ed <<
"Invalid charge "<<charge;
127 (
"G4TrajectoryDrawByCharge::Set(const G4int& charge, const G4Colour& colour)",
"modeling0122",
JustWarning, ed);
130 return Set(myCharge, colour);
134G4TrajectoryDrawByCharge::ConvertToCharge(
const G4String&
string, Charge& myCharge)
139 std::istringstream is(
string.c_str());
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
std::ostringstream G4ExceptionDescription
G4GLOB_DLL std::ostream G4cout
bool GetColour(const T &, G4Colour &) const
void Print(std::ostream &ostr) const
void Set(const T &, const G4Colour &)
virtual void Print(std::ostream &ostr) const
virtual void Draw(const G4VTrajectory &trajectory, const G4bool &visible=true) const
virtual ~G4TrajectoryDrawByCharge()
G4TrajectoryDrawByCharge(const G4String &name="Unspecified", G4VisTrajContext *context=0)
void Set(const Charge &charge, const G4Colour &colour)
const G4VisTrajContext & GetContext() const
G4bool GetVerbose() const
virtual G4double GetCharge() const =0
void SetLineColour(const G4Colour &colour)
void Print(std::ostream &ostr) const
void DrawLineAndPoints(const G4VTrajectory &traj, const G4VisTrajContext &)