DD4hep - The AIDA detector description toolkit for high energy physics experiments
DD4hep
Rev:Unversioneddirectory
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
DDCore
src
ToStream.cpp
Go to the documentation of this file.
1
//==========================================================================
2
// AIDA Detector description implementation for LCD
3
//--------------------------------------------------------------------------
4
// Copyright (C) Organisation europeenne pour la Recherche nucleaire (CERN)
5
// All rights reserved.
6
//
7
// For the licensing terms see $DD4hepINSTALL/LICENSE.
8
// For the list of contributors see $DD4hepINSTALL/doc/CREDITS.
9
//
10
// Author : M.Frank
11
//
12
//==========================================================================
13
14
// Framework include files
15
#if defined(DD4HEP_PARSER_HEADER)
16
17
#define DD4HEP_NEED_EVALUATOR
18
// This is the case, if the parsers are externalized
19
// and the DD4hep namespace is renamed!
20
#include DD4HEP_PARSER_HEADER
21
22
#else
23
24
// Standard DD4hep parser handling
25
#include "
DD4hep/ToStream.h
"
26
27
#endif
28
29
#ifndef DD4HEP_PARSERS_NO_ROOT
30
31
// ============================================================================
32
// print XYZ-point
33
std::ostream&
DD4hep::Utils::toStream
(
const
ROOT::Math::XYZPoint& obj, std::ostream&
s
) {
34
s <<
"( "
;
35
toStream
(obj.X () ,
s
);
36
s <<
" , "
;
37
toStream
(obj.Y () ,
s
);
38
s <<
" , "
;
39
toStream
(obj.Z () ,
s
);
40
s <<
" )"
;
41
return
s
;
42
}
43
// ============================================================================
44
// print XYZ-vector
45
std::ostream&
DD4hep::Utils::toStream
(
const
ROOT::Math::XYZVector& obj, std::ostream&
s
) {
46
s <<
"( "
;
47
toStream
(obj.X () ,
s
);
48
s <<
" , "
;
49
toStream
(obj.Y () ,
s
);
50
s <<
" , "
;
51
toStream
(obj.Z () ,
s
);
52
s <<
" )"
;
53
return
s
;
54
}
55
// ============================================================================
56
// print LorentzVector
57
std::ostream&
DD4hep::Utils::toStream
(
const
ROOT::Math::PxPyPzEVector& obj, std::ostream&
s
){
58
s <<
"( "
;
59
toStream
(obj.Px () ,
s
, 12 );
60
s <<
" , "
;
61
toStream
(obj.Py () ,
s
, 12 );
62
s <<
" , "
;
63
toStream
(obj.Pz () ,
s
, 13 );
64
s <<
" , "
;
65
toStream
(obj.E () ,
s
, 14 );
66
s <<
" )"
;
67
return
s
;
68
}
69
#endif
s
TGeoShape * s
Definition:
Volumes.cpp:294
DD4hep::Utils::toStream
std::ostream & toStream(const Property &result, std::ostream &os)
Definition:
ComponentProperties.cpp:226
ToStream.h
Generated on Fri Dec 2 2016 12:31:07 for DD4hep by
1.8.6