MLBookProc 2.1
Loading...
Searching...
No Matches
BaseID Class Reference

The BaseID class. More...

#include <BaseID.h>

Public Types

enum  ID {
  Dir , File , Symlink , Book ,
  BookTitle , SourceBookTitle , Author , SourceBookAuthor ,
  EbookAuthor , LastName , FirstName , MiddleName ,
  Translator , SourceBookTranslator , Sequence , SequenceName ,
  SequenceNumber , SourceBookSequence , PaperBookSequence , Genre ,
  SourceBookGenre , Date , EbookDate , Language ,
  SourceLanguage , SourceBookLanguage , SourceBookSourceLanguage , SourceBookDate ,
  Keywords , SourceBookKeywords , PathInFile , BookSearchResult ,
  FBDPath , SourceBookDublinCore , EbookProgramUsed , EbookSourceUrl ,
  EbookSourceOCR , EbookID , EbookVersion , EbookHistory ,
  EbookPublisher , PaperBookPublisher , PaperBookName , PaperBookCity ,
  PaperBookYear , PaperBookISBN , CustomInfo , DjvuPublisher ,
  CollectionInfo , CollectionType , CoverType , BooksDirectory ,
  InpxPath , FileHash , FileSize , Annotation ,
  CoverPage , CoverHeight , CoverWidth , Nickname ,
  HomePage , EMail , AuthorID , BookMark ,
  BookNote , BookNoteFile , AuthorSearchResult , AnchorBasePath ,
  Error
}
 The ID enum. More...

Public Member Functions

void setId (UDBElement &result, const ID &id)
ID getId (const UDBElement &el) const

Detailed Description

The BaseID class.

This class contains enumerator of all database object types and methods to set and get this types.

Member Enumeration Documentation

◆ ID

enum BaseID::ID

The ID enum.

Enumerator
Dir 

Objects of this type contain collection directory path.

File 

Objects of this type contain collection file path, FileHash, FileSize and Book objects.

Symlink 

Objects of this type contain collection symlink path (only files symlinks) and BaseID::File object.

Book 

Objects of this type contain information about book. Such object can include BaseID::Author, BaseID::BookTitle, BaseID::Genre, BaseID::Date, BaseID::PathInFile objects. content variable is empty.

BookTitle 

Objects of this type contain book name.

SourceBookTitle 

Objects of this type contain source book name

Author 

Objects of this type contain information about author. Such objects can include BaseID::LastName, BaseID::FirstName, BaseID::MiddleName, BaseID::Nickname, BaseID::HomePage, BaseID::EMail, and BaseID::AuthorID objects. content varible can contain author full name in free format.

SourceBookAuthor 

Objects of this type contain source book author information (same as BaseID::Author object).

EbookAuthor 

Objects of this type contain e-book author information (same as BaseID::Author object).

LastName 

Objects of this type contain author surname.

FirstName 

Objects of this type contain author first name.

MiddleName 

Objects of this type contain author second name.

Translator 

Objects of this type contain information about translator (same as BaseID::Author object).

SourceBookTranslator 

Objects of this type contain information about source book translator (same as BaseID::Author object).

Sequence 

Objects of this type contain book series information. Such object must contain SequenceName object and can contain SequenceNumber object.

SequenceName 

Objects of this type contain book series name.

SequenceNumber 

Objects of this type contain book number in series.

SourceBookSequence 

Objects of this type contain source book series information (same as BaseID::Sequence object).

PaperBookSequence 

Objects of this type contain paper book series information (same as BaseID::Sequence object).

Genre 

Objects of this type contain genre code.

SourceBookGenre 

Objects of this type contain source book genre code.

Date 

Objects of this type contain date book has been published or finished.

EbookDate 

Objects of this type contain date e-book has been published.

Language 

Objects of this type contain book language.

SourceLanguage 

Objects of this type contain book source language.

SourceBookLanguage 

Objects of this type contain source book language.

SourceBookSourceLanguage 

Objects of this type contain source book source language.

SourceBookDate 

Objects of this type contain date source book has been published or finished.

Keywords 

Objects of this type contain book keywords.

SourceBookKeywords 

Objects of this type contain source book keywords.

PathInFile 

Objects of this type contain book path in file (if file is archive). Such object can contain another BaseID::PathInFile object ('archive in archive' case) and BaseID::FBDPath object.

BookSearchResult 

Objects of this type are returned by various BaseKeeper methods. In most cases such object includes BaseID::File type object (without BaseID::FileHash and BaseID::FileSize) and BaseID::Book type object.

FBDPath 

Objects of this type contain path to fbd file in archive.

SourceBookDublinCore 

Objects of this type contain source book name obtained from Dublin Core file (used in epub, odt and mobi formats).

EbookProgramUsed 

Objects of this type contain name of program which has been used to create e-book.

EbookSourceUrl 

Objects of this type contain URL to e-book source.

EbookSourceOCR 

Objects of this type contain author of the original (online) document, if this is a conversion (free form).

EbookID 

Objects of this type contain e-book idetification.

EbookVersion 

Objects of this type contain e-book version.

EbookHistory 

Objects of this type contain e-book history of changes.

EbookPublisher 

Objects of this type contain e-book publisher (same as BaseID::Author object).

PaperBookPublisher 

Objects of this type contain paper book publisher.

PaperBookName 

Objects of this type contain paper book name.

PaperBookCity 

Objects of this type contain city where paper book has been published.

PaperBookYear 

Objects of this type contain year when paper book has been published.

PaperBookISBN 

Objects of this type contain paper book ISBN.

CustomInfo 

Objects of this type contain book custom info.

DjvuPublisher 

Objects of this type contain djvu document publisher.

CollectionInfo 

Objects of this type contain BaseID::CollectionType object and can contain BaseID::BooksDirectory and BaseID::InpxPath objects.

CollectionType 

Objects of this type contain collection type. Can be 'native', 'inpx' and 'legacy'.

CoverType 

Objects of this type contain book cover type. Can be 'image' (image which can be automatically recognized by graphical libraries, like jpg, png etc.), 'base64' (same as previous, but base64 encoded), 'text' (XML text), 'txt' (plain text), 'md' (Markdown text), 'ARGB' (ARGB image), 'RGB' (RGB image).

BooksDirectory 

Objects of this type contain path to books directory (used in 'inpx' and 'legacy' collection types).

InpxPath 

Objects of this type contain path to inpx file.

FileHash 

Objects of this type contain file hash (BLAKE2B).

FileSize 

Objects of this type contain file size (uint64_t little endian as raw bytes).

Annotation 

Objects of this type contain book annotation (can contain XML markup).

CoverPage 

Objects of this type contain book cover page. Must contain BaseID::CoverType object, can contain BaseID::CoverHeight and BaseID::CoverWidth objects.

CoverHeight 

Objects of this type contain cover page height in pixels (little endian unsigned integer as raw bytes).

CoverWidth 

Objects of this type contain cover page width in pixels (little endian unsigned integer as raw bytes).

Nickname 

Objects of this type contain nickname of author (translator, publisher).

HomePage 

Objects of this type contain author (translator, publisher) home page.

EMail 

Objects of this type contain author (translator, publisher) e-mail.

AuthorID 

Objects of this type contain author (translator, publisher) identification.

BookMark 

Objects of this type contain bookmark used in BookmarksKeeper. Should contains BaseID::File and BaseID::Book objects.

BookNote 

Objects of this type contain book notes used in NotesKeeper. Should contain BaseID::File, BaseID::BookNoteFile objects. Can contain BaseID::PathInFile object.

BookNoteFile 

Objects of this type contain path to book note file.

AuthorSearchResult 

Objects of this type contain author (free form).

AnchorBasePath 

Objects of this type contain 'anchor' path, used on collection export and import operations.

Error 

Invalid object.

Member Function Documentation

◆ getId()

ID BaseID::getId ( const UDBElement & el) const

Returns objects ID.

Note
This method can throw std::exception in case of errors.
Parameters
elUDBElement ID of which should be get.
Returns
BaseID::ID member.

◆ setId()

void BaseID::setId ( UDBElement & result,
const ID & id )

Sets objects ID.

Parameters
resultUDBElement ID to be set to.
idBaseID::ID member.