libdballe  9.11
Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Friends | List of all members
dballe::DBImportOptions Class Reference

Options controlling how messages are imported in the database. More...

#include <db.h>

Inheritance diagram for dballe::DBImportOptions:
dballe::impl::DBImportOptions

Static Public Member Functions

static std::unique_ptr< DBImportOptionscreate ()
 

Public Attributes

std::string report
 Report name to use to import data. More...
 
bool import_attributes = false
 Import variable attributes.
 
bool update_station = false
 Update station information. More...
 
bool overwrite = false
 Replace existing data. More...
 
std::vector< wreport::Varcodevarlist
 If not empty, import only the given data values.
 

Static Public Attributes

static const DBImportOptions defaults
 

Protected Member Functions

 DBImportOptions (const DBImportOptions &)=default
 
 DBImportOptions (DBImportOptions &&)=default
 
DBImportOptionsoperator= (const DBImportOptions &)=default
 
DBImportOptionsoperator= (DBImportOptions &&)=default
 

Friends

class DB
 
class Transaction
 

Detailed Description

Options controlling how messages are imported in the database.

To allow to add members this structure without breaking the ABI, creation of new instances is restricted to DBImportOptions::create().

Member Data Documentation

◆ overwrite

bool dballe::DBImportOptions::overwrite = false

Replace existing data.

If set to true, causes existing information already in the database to be overwritten. If false (default), trying to import a message which contains data already present in the database causes the import to fail.

◆ report

std::string dballe::DBImportOptions::report

Report name to use to import data.

If left empty (default), then it will be chosen automatically based on the message type.

◆ update_station

bool dballe::DBImportOptions::update_station = false

Update station information.

If set to true, station information is merged with existing data in the database. If false (default), station information is imported only when the station did not exist in the database.


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