List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes
io::ZHAireSFile Class Reference

#include <ZHAireSFile.h>

Inheritance diagram for io::ZHAireSFile:
Inheritance graph
[legend]

Public Member Functions

void Close () override
 
Status FindEvent (const unsigned int eventId) override
 seek Event id set cursor there More...
 
const std::string & GetFilename () const
 
int GetNEvents () override
 
Status GotoPosition (const unsigned int position) override
 goto by position in the file More...
 
void Open (const std::string &fileName, const Mode mode=eRead, utl::Branch *const b=nullptr) override
 
Status Read (evt::Event &event) override
 read current event advance cursor by 1 More...
 
void Write (const evt::Event &event) override
 
double ZHAireSAzimuthToAuger (const double airesAzimuth)
 Returns the azimuth rotated from AIRES's system to Auger standard. More...
 
 ZHAireSFile ()
 
 ZHAireSFile (const std::string &fileName, const Mode mode=eRead, utl::Branch *const b=nullptr)
 
virtual ~ZHAireSFile ()
 

Static Public Member Functions

static void Rotatez (const double theta, const double vi[], double vf[])
 

Protected Member Functions

int DefaultOpen (const std::string &filename, const Mode mode=eRead)
 
int DefaultWrite (evt::Event &event)
 

Protected Attributes

utl::BranchfBranch = nullptr
 
std::string fFilename
 
Mode fMode = eRead
 

Private Member Functions

ZHAireSFileoperator= (const ZHAireSFile &)
 
 ZHAireSFile (const ZHAireSFile &)
 

Private Attributes

double fBDeclination = 0
 
std::vector< std::string > fBinFileList
 
unsigned int fCurrentPosition = 0
 
std::ifstream * fdef = nullptr
 
std::string fHostName
 
std::string fOrigDirectory
 
unsigned long fProcessId
 
std::ifstream * fsry = nullptr
 
std::string fZHAireSDirectory
 
std::ifstream * fZHAireSin = nullptr
 
std::ofstream logfile
 

Detailed Description

Definition at line 24 of file ZHAireSFile.h.

Constructor & Destructor Documentation

io::ZHAireSFile::ZHAireSFile ( )
inline

Definition at line 27 of file ZHAireSFile.h.

io::ZHAireSFile::ZHAireSFile ( const std::string &  fileName,
const Mode  mode = eRead,
utl::Branch *const  b = nullptr 
)

Definition at line 67 of file ZHAireSFile.cc.

References logfile, and Open().

io::ZHAireSFile::~ZHAireSFile ( )
virtual

Definition at line 56 of file ZHAireSFile.cc.

io::ZHAireSFile::ZHAireSFile ( const ZHAireSFile )
private

Member Function Documentation

void io::ZHAireSFile::Close ( )
overridevirtual

Implements io::VEventFile.

Definition at line 210 of file ZHAireSFile.cc.

References fdef, fHostName, fProcessId, fsry, fZHAireSin, and utl::System().

int VEventFile::DefaultOpen ( const std::string &  filename,
const Mode  mode = eRead 
)
protectedinherited

Checks that file exists Intended to be called in the Write method of derived classes

Definition at line 31 of file VEventFile.cc.

Referenced by io::VROOTFile::Open(), io::AiresShowerFile::Open(), io::VEventFile::VEventFile(), and io::VROOTFile::VROOTFile().

int VEventFile::DefaultWrite ( evt::Event event)
protectedinherited

Checks that we are open for write Intended to be called in the Write method of derived classes

Definition at line 15 of file VEventFile.cc.

References io::eRead, and FATAL.

Status io::ZHAireSFile::FindEvent ( const unsigned int  eventId)
overridevirtual

seek Event id set cursor there

Implements io::VEventFile.

Definition at line 843 of file ZHAireSFile.cc.

References GotoPosition().

const std::string& io::VEventFile::GetFilename ( ) const
inlineinherited

Definition at line 54 of file VEventFile.h.

References io::VEventFile::fFilename.

Referenced by io::EventFile::GetFilename().

int io::ZHAireSFile::GetNEvents ( )
inlineoverridevirtual

Implements io::VEventFile.

Definition at line 37 of file ZHAireSFile.h.

Referenced by GotoPosition(), and Read().

Status io::ZHAireSFile::GotoPosition ( const unsigned int  position)
overridevirtual

goto by position in the file

Implements io::VEventFile.

Definition at line 851 of file ZHAireSFile.cc.

References io::eFail, io::eSuccess, and GetNEvents().

Referenced by FindEvent().

void io::ZHAireSFile::Open ( const std::string &  fileName,
const Mode  mode = eRead,
utl::Branch *const  b = nullptr 
)
overridevirtual

Implements io::VEventFile.

Definition at line 79 of file ZHAireSFile.cc.

References io::eRead, ERROR, fdef, fHostName, fProcessId, fsry, fZHAireSin, INFO, logfile, and utl::System().

Referenced by ZHAireSFile().

ZHAireSFile& io::ZHAireSFile::operator= ( const ZHAireSFile )
private
Status io::ZHAireSFile::Read ( evt::Event event)
overridevirtual

read current event advance cursor by 1

Implements io::VEventFile.

Definition at line 231 of file ZHAireSFile.cc.

References evt::RadioSimulation::AddSimRadioPulse(), utl::cm, utl::cm2, utl::deg, degree, io::eEOF, galactic::EeV, io::eFail, RdREASSimPreparator::eProton, ERROR, io::eSuccess, galactic::eV, fBDeclination, fCurrentPosition, fdef, fsry, fZHAireSin, utl::g, galactic::gauss, evt::SimRadioPulse::GetBinning(), evt::RadioSimulation::GetCorePosition(), evt::SimRadioPulse::GetEfieldTimeSeries(), evt::ShowerSimData::GetEnergy(), evt::RadioSimulation::GetEventNumber(), evt::RadioSimulation::GetEventTime(), utl::TimeStamp::GetGPSNanoSecond(), utl::TimeStamp::GetGPSSecond(), evt::ShowerSimData::GetGroundParticleCoordinateSystemAzimuth(), evt::ShowerSimData::GetGroundParticleCoordinateSystemZenith(), utl::UTMPoint::GetHeight(), evt::RadioSimulation::GetLocalCoordinateSystem(), evt::SimRadioPulse::GetLocation(), evt::ShowerSimData::GetMagneticFieldDeclination(), evt::ShowerSimData::GetMagneticFieldInclination(), evt::ShowerSimData::GetMagneticFieldStrength(), GetNEvents(), evt::RadioSimulation::GetNumPulses(), evt::ShowerSimData::GetPrimaryParticle(), evt::ShowerSimData::GetRadioSimulation(), evt::RadioSimulation::GetRunNumber(), evt::ShowerSimData::GetShowerNumber(), evt::ShowerSimData::GetShowerRunId(), evt::RadioSimulation::GetSimPulseByIndex(), evt::SimRadioPulse::GetStartTime(), utl::ReferenceEllipsoid::GetWGS84(), utl::BasicVector< HepVector >::GetX(), utl::BasicVector< HepVector >::GetY(), utl::BasicVector< HepVector >::GetZ(), utl::GeV, evt::RadioSimulation::HasCorePosition(), evt::ShowerSimData::HasRadioSimulation(), evt::Event::HasSimShower(), INFO, utl::keV, km, logfile, utl::m, evt::ShowerSimData::MakeRadioSimulation(), evt::ShowerSimData::MakeTimeStamp(), galactic::meter, utl::MeV, utl::nanosecond, ns, PeV, utl::Trace< T >::PushBack(), Rotatez(), evt::SimRadioPulse::SetBinning(), evt::RadioSimulation::SetCoreCoordinates(), evt::ShowerSimData::SetEnergy(), evt::RadioSimulation::SetEventNumber(), evt::RadioSimulation::SetEventTime(), evt::ShowerSimData::SetGroundParticleCoordinateSystemAzimuth(), evt::ShowerSimData::SetGroundParticleCoordinateSystemZenith(), evt::SimRadioPulse::SetLocalCoordinateSystem(), evt::ShowerSimData::SetPrimaryParticle(), evt::SimRadioPulse::SetRelativeCoordinates(), evt::RadioSimulation::SetRunNumber(), evt::ShowerSimData::SetShowerNumber(), evt::ShowerSimData::SetShowerRunId(), evt::SimRadioPulse::SetStartTime(), utl::TeV, V, galactic::volt, WARNING, and ZHAireSAzimuthToAuger().

static void io::ZHAireSFile::Rotatez ( const double  theta,
const double  vi[],
double  vf[] 
)
inlinestatic

Definition at line 50 of file ZHAireSFile.h.

Referenced by Read().

void io::ZHAireSFile::Write ( const evt::Event event)
overridevirtual

Implements io::VEventFile.

Definition at line 834 of file ZHAireSFile.cc.

References ERROR.

double io::ZHAireSFile::ZHAireSAzimuthToAuger ( const double  airesAzimuth)
inline

Returns the azimuth rotated from AIRES's system to Auger standard.

Definition at line 41 of file ZHAireSFile.h.

References utl::deg, fBDeclination, io::Aires::kMagneticFieldDeclination, utl::NormalizeAngleMinusPiPi(), and utl::rad.

Referenced by Read().

Member Data Documentation

double io::ZHAireSFile::fBDeclination = 0
private

Definition at line 64 of file ZHAireSFile.h.

Referenced by Read(), and ZHAireSAzimuthToAuger().

std::vector<std::string> io::ZHAireSFile::fBinFileList
private

Definition at line 65 of file ZHAireSFile.h.

utl::Branch* io::VEventFile::fBranch = nullptr
protectedinherited

Definition at line 72 of file VEventFile.h.

unsigned int io::ZHAireSFile::fCurrentPosition = 0
private

Definition at line 63 of file ZHAireSFile.h.

Referenced by Read().

std::ifstream* io::ZHAireSFile::fdef = nullptr
private

Definition at line 68 of file ZHAireSFile.h.

Referenced by Close(), Open(), and Read().

std::string io::VEventFile::fFilename
protectedinherited
std::string io::ZHAireSFile::fHostName
private

Definition at line 73 of file ZHAireSFile.h.

Referenced by Close(), and Open().

Mode io::VEventFile::fMode = eRead
protectedinherited
std::string io::ZHAireSFile::fOrigDirectory
private

Definition at line 70 of file ZHAireSFile.h.

unsigned long io::ZHAireSFile::fProcessId
private

Definition at line 74 of file ZHAireSFile.h.

Referenced by Close(), and Open().

std::ifstream* io::ZHAireSFile::fsry = nullptr
private

Definition at line 67 of file ZHAireSFile.h.

Referenced by Close(), Open(), and Read().

std::string io::ZHAireSFile::fZHAireSDirectory
private

Definition at line 71 of file ZHAireSFile.h.

std::ifstream* io::ZHAireSFile::fZHAireSin = nullptr
private

Definition at line 66 of file ZHAireSFile.h.

Referenced by Close(), Open(), and Read().

std::ofstream io::ZHAireSFile::logfile
private

Definition at line 76 of file ZHAireSFile.h.

Referenced by Open(), Read(), and ZHAireSFile().


The documentation for this class was generated from the following files:

, generated on Tue Sep 26 2023.