6 #include "nlohmann/json.hpp"
16 return StatusCode::SUCCESS;
19 const EventContext& ctx = Gaudi::Hive::currentContext();
21 if (!aLineContainer.isValid()){
23 return StatusCode::FAILURE;
26 if (!aLineContainer.isValid()){
28 return StatusCode::FAILURE;
34 return StatusCode::FAILURE;
37 unsigned int nLines{0};
38 for (
const ALinePar& aLine : **aLineContainer) {
40 ostr<<
" {"<<std::endl;
42 ostr<<
" \"typ\": \""<<aLine.AmdbStation()<<
"\","<<std::endl;
43 ostr<<
" \"jzz\": "<<aLine.AmdbEta()<<
", "<<std::endl;
44 ostr<<
" \"jff\": "<<aLine.AmdbPhi()<<
", "<<std::endl;
45 ostr<<
" \"job\": "<<aLine.AmdbJob()<<
", "<<std::endl;
48 ostr<<
" \"svalue\": "<<aLine.getParameter(APar::transS)<<
", "<<std::endl;
49 ostr<<
" \"zvalue\": "<<aLine.getParameter(APar::transZ)<<
", "<<std::endl;
50 ostr<<
" \"tvalue\": "<<aLine.getParameter(APar::transT)<<
", "<<std::endl;
51 ostr<<
" \"tsv\": "<<aLine.getParameter(APar::rotS)<<
", "<<std::endl;
52 ostr<<
" \"tzv\": "<<aLine.getParameter(APar::rotZ)<<
", "<<std::endl;
53 ostr<<
" \"ttv\": "<<aLine.getParameter(APar::rotT);
55 BLineContainer::const_iterator itr = bLineContainer->find(aLine.identify());
56 if (itr == bLineContainer->end()) {
58 ostr<<std::endl<<
" }"<< (nLines != aLineContainer->size() ?
"," :
"")<<std::endl;
65 ostr<<
" \"bp\": "<<bLine.
getParameter(BPar::bp)<<
","<<std::endl;
67 ostr<<
" \"sp\": "<<bLine.
getParameter(BPar::sp)<<
","<<std::endl;
68 ostr<<
" \"sn\": "<<bLine.
getParameter(BPar::sn)<<
","<<std::endl;
69 ostr<<
" \"tw\": "<<bLine.
getParameter(BPar::tw)<<
","<<std::endl;
71 ostr<<
" \"tr\": "<<bLine.
getParameter(BPar::tr)<<
","<<std::endl;
73 ostr<<
" \"ep\": "<<bLine.
getParameter(BPar::ep)<<
","<<std::endl;
76 ostr<<
" \"xAtlas\": 0 ,"<<std::endl;
77 ostr<<
" \"yAtlas\": 0 ,"<<std::endl;
78 ostr<<
" \"hwElement\": \"";
81 ostr<<std::abs(stEta)<<(stEta > 0 ?
"A" :
"C");
83 ostr<<
"\""<<std::endl;
84 ostr<<
" }"<< (nLines != aLineContainer->size() ?
"," :
"")<<std::endl;
90 return StatusCode::SUCCESS;