xapian-core
1.4.26
|
GlassVersion class. More...
#include <config.h>
#include "glass_version.h"
#include "debuglog.h"
#include "fd.h"
#include "io_utils.h"
#include "omassert.h"
#include "pack.h"
#include "posixy_wrapper.h"
#include "stringutils.h"
#include <cerrno>
#include <cstring>
#include <string>
#include <sys/types.h>
#include "safesysstat.h"
#include "safefcntl.h"
#include "safeunistd.h"
#include "str.h"
#include "backends/uuids.h"
#include "xapian/constants.h"
#include "xapian/error.h"
Go to the source code of this file.
Namespaces | |
Glass | |
Macros | |
#define | GLASS_FORMAT_VERSION DATE_TO_VERSION(2016,03,14) |
Glass format version (date of change): More... | |
#define | DATE_TO_VERSION(Y, M, D) ((unsigned(Y) - 2014) << 9 | unsigned(M) << 5 | unsigned(D)) |
Convert date <-> version number. Dates up to 2141-12-31 fit in 2 bytes. More... | |
#define | VERSION_TO_YEAR(V) ((unsigned(V) >> 9) + 2014) |
#define | VERSION_TO_MONTH(V) ((unsigned(V) >> 5) & 0x0f) |
#define | VERSION_TO_DAY(V) (unsigned(V) & 0x1f) |
#define | GLASS_VERSION_MAGIC_LEN 14 |
#define | GLASS_VERSION_MAGIC_AND_VERSION_LEN 16 |
Variables | |
static const char | GLASS_VERSION_MAGIC [GLASS_VERSION_MAGIC_AND_VERSION_LEN] |
const size_t | COMPRESS_MIN = 18 |
static const uint4 | compress_min_tab [] |
GlassVersion class.
Definition in file glass_version.cc.
#define DATE_TO_VERSION | ( | Y, | |
M, | |||
D | |||
) | ((unsigned(Y) - 2014) << 9 | unsigned(M) << 5 | unsigned(D)) |
Convert date <-> version number. Dates up to 2141-12-31 fit in 2 bytes.
Definition at line 58 of file glass_version.cc.
#define GLASS_FORMAT_VERSION DATE_TO_VERSION(2016,03,14) |
Glass format version (date of change):
Definition at line 52 of file glass_version.cc.
Referenced by GlassVersion::read().
#define GLASS_VERSION_MAGIC_AND_VERSION_LEN 16 |
Definition at line 65 of file glass_version.cc.
Referenced by GlassVersion::read(), and GlassVersion::write().
#define GLASS_VERSION_MAGIC_LEN 14 |
Definition at line 64 of file glass_version.cc.
Referenced by GlassVersion::read().
#define VERSION_TO_DAY | ( | V | ) | (unsigned(V) & 0x1f) |
Definition at line 62 of file glass_version.cc.
Referenced by GlassVersion::read().
#define VERSION_TO_MONTH | ( | V | ) | ((unsigned(V) >> 5) & 0x0f) |
Definition at line 61 of file glass_version.cc.
Referenced by GlassVersion::read().
#define VERSION_TO_YEAR | ( | V | ) | ((unsigned(V) >> 9) + 2014) |
Definition at line 60 of file glass_version.cc.
Referenced by GlassVersion::read().
const size_t COMPRESS_MIN = 18 |
Definition at line 385 of file glass_version.cc.
Referenced by Glass::RootInfo::unserialise().
|
static |
Definition at line 387 of file glass_version.cc.
Referenced by GlassVersion::create().
|
static |
Definition at line 67 of file glass_version.cc.
Referenced by GlassVersion::read(), and GlassVersion::write().