|
MIDAS
|
#include "midas.h"#include "msystem.h"#include "mstrlcpy.h"#include <math.h>#include <vector>#include <list>#include <string>#include <map>#include <algorithm>#include "history.h"
Go to the source code of this file.
Classes | |
| struct | HsSchemaEntry |
| class | HsSchema |
| class | HsSchemaVector |
| class | SqlBase |
| class | HsSqlSchema |
| class | HsFileSchema |
| class | SchemaHistoryBase |
| class | SchemaHistoryBase::ReadBuffer |
| class | SqlHistoryBase |
| class | SqliteHistory |
| class | MysqlHistory |
| class | FileHistory |
Macros | |
| #define | FREE(x) { if (x) free(x); (x) = NULL; } |
Functions | |
| static char * | skip_spaces (char *s) |
| static std::string | TimeToString (time_t t) |
| static std::string | SmallIntToString (int i) |
| static bool | MatchEventName (const char *event_name, const char *var_event_name) |
| static bool | MatchTagName (const char *tag_name, int n_data, const char *var_tag_name, const int var_tag_index) |
| static void | PrintTags (int ntags, const TAG tags[]) |
| static std::string | MidasNameToSqlName (const char *s) |
| static std::string | MidasNameToFileName (const char *s) |
| static int | event_name_cmp (const std::string &e1, const char *e2) |
| static int | var_name_cmp (const std::string &v1, const char *v2) |
| void | DoctorPgsqlColumnType (std::string *col_type, const char *index_type) |
| void | DoctorSqlColumnType (std::string *col_type, const char *index_type) |
| static int | ReadRecord (const char *file_name, int fd, off64_t offset, size_t recsize, off64_t irec, char *rec) |
| static int | FindTime (const char *file_name, int fd, off64_t offset, size_t recsize, off64_t nrec, time_t timestamp, off64_t *i1p, time_t *t1p, off64_t *i2p, time_t *t2p, time_t *tstart, time_t *tend, int debug) |
| static HsSqlSchema * | NewSqlSchema (HsSchemaVector *sv, const char *table_name, time_t t) |
| static int | StartSqlTransaction (SqlBase *sql, const char *table_name, bool *have_transaction) |
| static int | CreateSqlTable (SqlBase *sql, const char *table_name, bool *have_transaction, bool set_default_timestamp=false) |
| static int | CreateSqlHyperTable (SqlBase *sql, const char *table_name, bool *have_transaction) |
| static int | CreateSqlColumn (SqlBase *sql, const char *table_name, const char *column_name, const char *column_type, bool *have_transaction, int debug) |
| static int | ReadSqliteTableNames (SqlBase *sql, HsSchemaVector *sv, const char *table_name, int debug) |
| static int | ReadSqliteTableSchema (SqlBase *sql, HsSchemaVector *sv, const char *table_name, int debug) |
| static int | ReadMysqlTableNames (SqlBase *sql, HsSchemaVector *sv, const char *table_name, int debug, const char *must_have_event_name, const char *must_have_table_name) |
| MidasHistoryInterface * | MakeMidasHistorySqlite () |
| MidasHistoryInterface * | MakeMidasHistoryMysql () |
| MidasHistoryInterface * | MakeMidasHistoryPgsql () |
| MidasHistoryInterface * | MakeMidasHistoryFile () |
Variables | |
| const time_t | kDay = 24*60*60 |
| const time_t | kMonth = 30*kDay |
| const double | KiB = 1024 |
| const double | MiB = KiB*KiB |
| #define FREE | ( | x | ) | { if (x) free(x); (x) = NULL; } |
Definition at line 53 of file history_schema.cxx.
|
static |
Definition at line 4748 of file history_schema.cxx.


|
static |
Definition at line 4674 of file history_schema.cxx.

|
static |
Definition at line 4607 of file history_schema.cxx.


| void DoctorPgsqlColumnType | ( | std::string * | col_type, |
| const char * | index_type | ||
| ) |
Definition at line 300 of file history_schema.cxx.

| void DoctorSqlColumnType | ( | std::string * | col_type, |
| const char * | index_type | ||
| ) |
Definition at line 325 of file history_schema.cxx.


|
static |
Definition at line 218 of file history_schema.cxx.

|
static |
Definition at line 2623 of file history_schema.cxx.


| MidasHistoryInterface * MakeMidasHistoryFile | ( | ) |
| MidasHistoryInterface * MakeMidasHistoryMysql | ( | ) |
Definition at line 7264 of file history_schema.cxx.


| MidasHistoryInterface * MakeMidasHistoryPgsql | ( | ) |
Definition at line 7274 of file history_schema.cxx.


| MidasHistoryInterface * MakeMidasHistorySqlite | ( | ) |
Definition at line 7254 of file history_schema.cxx.


|
static |
Definition at line 116 of file history_schema.cxx.


|
static |
Definition at line 159 of file history_schema.cxx.

|
static |
Definition at line 201 of file history_schema.cxx.

|
static |
Definition at line 184 of file history_schema.cxx.

|
static |
Definition at line 4156 of file history_schema.cxx.


|
static |
Definition at line 176 of file history_schema.cxx.


|
static |
Definition at line 5588 of file history_schema.cxx.


|
static |
Definition at line 2592 of file history_schema.cxx.


|
static |
Definition at line 5238 of file history_schema.cxx.


|
static |
Definition at line 5283 of file history_schema.cxx.


|
static |
Definition at line 55 of file history_schema.cxx.
|
static |
Definition at line 95 of file history_schema.cxx.

|
static |
Definition at line 4594 of file history_schema.cxx.


|
static |
Definition at line 65 of file history_schema.cxx.

|
static |
Definition at line 225 of file history_schema.cxx.

| const time_t kDay = 24*60*60 |
Definition at line 6444 of file history_schema.cxx.
| const double KiB = 1024 |
Definition at line 6447 of file history_schema.cxx.
| const time_t kMonth = 30*kDay |
Definition at line 6445 of file history_schema.cxx.
Definition at line 6448 of file history_schema.cxx.