libdballe  9.11
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Friends | List of all members
dballe::fortran::DbAPI Struct Reference
Inheritance diagram for dballe::fortran::DbAPI:
dballe::fortran::CommonAPIImplementation dballe::fortran::API

Public Member Functions

 DbAPI (std::shared_ptr< db::Transaction > tr, const char *anaflag, const char *dataflag, const char *attrflag)
 
 DbAPI (std::shared_ptr< db::Transaction > tr, unsigned perms)
 
void seti (const char *param, int value) override
 
void reinit_db (const char *repinfofile=nullptr) override
 
void remove_all () override
 
int query_stations () override
 
int query_data () override
 
void insert_data () override
 
void remove_data () override
 
void commit () override
 
void messages_open_input (const char *filename, const char *mode, Encoding format, bool simplified=true) override
 
void messages_open_output (const char *filename, const char *mode, Encoding format) override
 
bool messages_read_next () override
 
void messages_write_next (const char *template_name=0) override
 
- Public Member Functions inherited from dballe::fortran::CommonAPIImplementation
 CommonAPIImplementation (const CommonAPIImplementation &)=delete
 
 CommonAPIImplementation (CommonAPIImplementation &&)=delete
 
CommonAPIImplementationoperator= (const CommonAPIImplementation &)=delete
 
CommonAPIImplementationoperator= (CommonAPIImplementation &&)=delete
 
template<typename Operation >
auto reset_operation (Operation *op) -> decltype(op->run())
 
void reset_operation ()
 
int enqi (const char *param) override
 
signed char enqb (const char *param) override
 
float enqr (const char *param) override
 
double enqd (const char *param) override
 
bool enqc (const char *param, char *res, unsigned res_len) override
 
void setb (const char *param, signed char value) override
 
void setr (const char *param, float value) override
 
void setd (const char *param, double value) override
 
void setc (const char *param, const char *value) override
 
void set_station_context () override
 
void enqlevel (int &ltype1, int &l1, int &ltype2, int &l2) override
 
void setlevel (int ltype1, int l1, int ltype2, int l2) override
 
void enqtimerange (int &ptype, int &p1, int &p2) override
 
void settimerange (int ptype, int p1, int p2) override
 
void enqdate (int &year, int &month, int &day, int &hour, int &min, int &sec) override
 
void setdate (int year, int month, int day, int hour, int min, int sec) override
 
void setdatemin (int year, int month, int day, int hour, int min, int sec) override
 
void setdatemax (int year, int month, int day, int hour, int min, int sec) override
 
void unset (const char *param) override
 
void unsetall () override
 
void unsetb () override
 
const char * describe_level (int ltype1, int l1, int ltype2, int l2) override
 
const char * describe_timerange (int ptype, int p1, int p2) override
 
const char * describe_var (const char *varcode, const char *value) override
 
void next_station () override
 
wreport::Varcode next_data () override
 
int query_attributes () override
 
const char * next_attribute () override
 
void insert_attributes () override
 
void remove_attributes () override
 
const Operationtest_get_operation () const
 
const core::Querytest_get_input_query () const
 
const core::Datatest_get_input_data () const
 
const Valuestest_get_qcinput () const
 
- Public Member Functions inherited from dballe::fortran::API
const char * test_enqc (const char *param, unsigned len)
 Wrap enqc in a way that makes it easier to use in unit tests. More...
 

Static Public Member Functions

static std::unique_ptr< APIfortran_connect (const DBConnectOptions &options, const char *anaflag, const char *dataflag, const char *attrflag)
 
- Static Public Member Functions inherited from dballe::fortran::CommonAPIImplementation
static unsigned compute_permissions (const char *anaflag, const char *dataflag, const char *attrflag)
 Set the permission bits, parsing the flags and doing consistency checks.
 
- Static Public Member Functions inherited from dballe::fortran::API
static void to_fortran (int32_t val, char *buf, unsigned buf_len)
 
static void to_fortran (const char *str, char *buf, unsigned buf_len)
 
static void to_fortran (const std::string &str, char *buf, unsigned buf_len)
 

Public Attributes

std::shared_ptr< db::Transactiontr
 
InputFile * input_file = nullptr
 
OutputFile * output_file = nullptr
 
- Public Attributes inherited from dballe::fortran::CommonAPIImplementation
unsigned perms = 0
 
core::Query input_query
 
wreport::Varcode input_query_var = 0
 
std::set< wreport::Varcodeinput_query_varlist
 
core::Data input_data
 
std::vector< wreport::Varcodeselected_attr_codes
 Selected attribute varcodes (*varlist)
 
bool station_context = false
 
Values qcinput
 
Attributes qcoutput
 

Protected Member Functions

void shutdown (bool commit)
 
- Protected Member Functions inherited from dballe::fortran::CommonAPIImplementation
bool _seti (const char *key, unsigned len, int val)
 
bool _setd (const char *key, unsigned len, double val)
 
bool _setc (const char *key, unsigned len, const char *val)
 
bool _unset (const char *key, unsigned len)
 
void validate_input_query ()
 

Friends

class Operation
 

Additional Inherited Members

- Public Types inherited from dballe::fortran::CommonAPIImplementation
enum  Permissions {
  PERM_ANA_RO = (1 << 0), PERM_ANA_WRITE = (1 << 1), PERM_DATA_RO = (1 << 2), PERM_DATA_ADD = (1 << 3),
  PERM_DATA_WRITE = (1 << 4), PERM_ATTR_RO = (1 << 5), PERM_ATTR_WRITE = (1 << 6)
}
 
- Static Public Attributes inherited from dballe::fortran::API
static const signed char missing_byte
 
static const int missing_int
 
static const float missing_float
 
static const double missing_double
 
- Protected Attributes inherited from dballe::fortran::CommonAPIImplementation
Operationoperation = nullptr
 
std::string cached_spiega
 

The documentation for this struct was generated from the following file: