76
75
static const std::string MATCH_PARTIAL("PARTIAL");
77
76
static const std::string MATCH_SIMPLE("SIMPLE");
79
void init(drizzled::message::Table &arg, const std::string &name_arg, const std::string &schema_arg, const std::string &engine_arg)
81
arg.set_name(name_arg);
82
arg.set_schema(schema_arg);
83
arg.set_creation_timestamp(time(NULL));
84
arg.set_update_timestamp(time(NULL));
85
arg.mutable_engine()->set_name(engine_arg);
87
/* 36 characters for uuid string +1 for NULL */
90
uuid_generate_random(uu);
91
uuid_unparse(uu, uuid_string);
92
arg.set_uuid(uuid_string, 36);
97
void init(drizzled::message::Schema &arg, const std::string &name_arg)
99
arg.set_name(name_arg);
100
arg.mutable_engine()->set_name(std::string("filesystem")); // For the moment we have only one.
101
if (not arg.has_collation())
103
arg.set_collation(default_charset_info->name);
106
/* 36 characters for uuid string +1 for NULL */
108
char uuid_string[37];
109
uuid_generate_random(uu);
110
uuid_unparse(uu, uuid_string);
111
arg.set_uuid(uuid_string, 36);
116
78
void update(drizzled::message::Schema &arg)
118
80
arg.set_version(arg.version() + 1);