(
"volume_id", &volume_id);
73 BindData(
"raw_status", &raw_status);
76 BindData(
"date_from", &date_from);
78 BindData(
"mtimestamp", &mtimestamp);
79 BindData(
"relo_volume_id", &relo_volume_id);
81 BindData(
"backup_loc", &backup_loc, 1024);
121 void Open(
const string& dir_path);
130 const SVolumesDB& FetchVolumeRec(
unsignedvolume_id);
139 unsignedAddVolume(
const string&
location,
142EVolumeStatus status = eOffline);
145 voidSetBackupLocation(
unsignedvolume_id,
const string& backup_loc);
148 voidChangeStatus(
unsignedvolume_id, EVolumeStatus status);
154 voidLockVolume(
unsignedvolume_id);
157 voidUnLockVolume(
unsignedvolume_id);
162 voidSwitchVolumes(
unsignedvolume_id_old,
163 unsignedvolume_id_new,
164EVolumeStatus new_status = eOnlineActive);
168 voidSplit(
unsignedvolume_id_old,
169 unsignedvolume_id_new1,
170 unsignedvolume_id_new2,
171EVolumeStatus new_status = eOnlineActive);
174 void Delete(
constvector<unsigned>& remove_list);
180 void Merge(
unsignedvolume_id_new,
181 constvector<unsigned>& merge_list,
182EVolumeStatus new_status = eOnlineActive);
185 voidSetDateRange(
unsignedvolume_id,
195 voidEnumerateVolumes(vector<unsigned>& vlist,
boolavail =
false);
198 static stringStatusToString(EVolumeStatus status);
201 boolx_CheckStatusChange(EVolumeStatus old_status,
202EVolumeStatus new_status);
203 voidx_ChangeCurrentStatus(
unsignedvolume_id,
204EVolumeStatus status);
230 switch(GetErrCode())
Wrapper around Berkeley DB environment structure.
Base BDB exception class.
String field type designed to work with C-strings (ASCIIZ)
Exceptions specific to volumes management.
@ eTransactionsNotAvailable
NCBI_EXCEPTION_DEFAULT(CBDB_VolumesException, CBDB_Exception)
virtual const char * GetErrCodeString(void) const override
Transaction class for volumes management.
CBDB_Volumes(const CBDB_Volumes &)
CBDB_Volumes & operator=(const CBDB_Volumes &)
unique_ptr< CBDB_Env > m_Env
EVolumeStatus
Volume status codes.
@ eOnlineMaintenance
Online, readable, under background processing.
@ eOnlineActive
Online, new updates can come.
@ eOffline
Offline, unmounted.
@ eOfflineRelocated
Offline, data moved to another volume.
@ eOfflineArchived
Offline, data moved to archive.
unique_ptr< SVolumesDB > m_VolumesDB
Include a standard set of the NCBI C++ Toolkit most basic headers.
static const char location[]
EBDB_ErrCode Delete(EIgnoreError on_error=eThrowOnError)
Delete record corresponding to the current key value.
void Open(const string &filename, EOpenMode open_mode, bool support_dirty_read=false, unsigned rec_len=0)
Open file with specified access mode.
void DisableNull()
Disable NULL/not NULL in data fields (Performance tweak, call before BindData)
void BindKey(const char *field_name, CBDB_Field *key_field, size_t buf_size=0)
void BindData(const char *field_name, CBDB_Field *data_field, size_t buf_size=0, ENullable is_null=eNullable)
virtual const char * GetErrCodeString(void) const
Get error code interpreted as text.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
const string version
version string
Defines NCBI C++ exception handling.
Miscellaneous common-use basic types and functionality.
BDB file for storing volumes registry.
CBDB_FieldUint4 lock
Volume lock counter.
CBDB_FieldUint4 relo_volume_id
Modification date.
CBDB_FieldUint4 raw_status
Raw data status.
SVolumesDB(const SVolumesDB &)
SVolumesDB & operator=(const SVolumesDB &)
CBDB_FieldUint4 version
Volume version.
CBDB_FieldUint4 volume_id
Volume ID.
CBDB_FieldUint4 mtimestamp
Modification date.
CBDB_FieldUint4 type
Volume type.
CBDB_FieldUint4 date_from
Date interval.
CBDB_FieldString location
Mount point for the volume.
CBDB_FieldUint4 status
Volume status.
CBDB_FieldString backup_loc
Location of volume backup.
CBDB_FieldUint4 date_to
Date interval.
void Merge(wxMenu &menu_1, const wxMenu &menu_2)
merges all items form menu_2 into menu_1, preserving the structure if possible
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4