71 const std::string& method =
"LOG",
72 const double& gamma = 1.0);
85 const GEnergy&
at(
const int& index)
const;
90 void remove(
const int& index);
94 void set(
const int& num,
97 const std::string& method =
"LOG",
98 const double& gamma = 1.0);
101 const bool& clobber =
false)
const;
115 const double& gamma);
130 return (
"GEnergies");
std::string print(const GChatter &chatter=NORMAL) const
Print energy container information.
void clear(void)
Clear energy container.
void read(const GFitsTable &table)
Read energies from FITS table.
Energy value class definition.
void write(GFits &file, const std::string &extname=gammalib::extname_energies) const
Write energies into FITS object.
void set_pow(const int &num, const GEnergy &emin, const GEnergy &emax, const double &gamma)
Set power-law spaced energy intervals.
void reserve(const int &num)
Reserves space for energies in container.
void set_lin(const int &num, const GEnergy &emin, const GEnergy &emax)
Set linearly spaced energies.
FITS file class interface definition.
virtual ~GEnergies(void)
Destructor.
void free_members(void)
Delete class members.
GEnergy & insert(const int &index, const GEnergy &energy)
Insert energy into container.
std::vector< GEnergy > m_energies
List of energies.
GEnergies(void)
Void constructor.
Energy boundaries container class.
GEnergy & at(const int &index)
Return reference to energy.
int size(void) const
Return number of energies in container.
Abstract interface for FITS table.
GEnergy & operator[](const int &index)
Return reference to energy.
void extend(const GEnergies &energies)
Append energy container.
void save(const GFilename &filename, const bool &clobber=false) const
Save energies into FITS file.
bool is_empty(void) const
Signals if there are no energies in container.
const std::string extname_energies
void set(const GEbounds &ebounds)
Set energies from energy boundaries.
GEnergies & operator=(const GEnergies &energies)
Assignment operator.
GEnergy & append(const GEnergy &energy)
Append energy to container.
void copy_members(const GEnergies &energies)
Copy class members.
std::string classname(void) const
Return class name.
Definition of interface for container classes.
GEnergies * clone(void) const
Clone energy container.
void set_log(const int &num, const GEnergy &emin, const GEnergy &emax)
Set logarithmically spaced energies.
void load(const GFilename &filename)
Load energies from FITS file.
void init_members(void)
Initialise class members.
Interface class for container classes.
Class that handles energies in a unit independent way.
FITS table abstract base class interface definition.