drizzle
C++ MySQL-protocol-compatible database server
Loading...
Searching...
No Matches
drizzle_plugin::json_server::Schema Class Reference

#include <schema.h>

Collaboration diagram for drizzle_plugin::json_server::Schema:
[legend]

Public Member Functions

 Schema (Session *in_session, string db_name)
bool createSchema ()
bool dropSchema ()
Session & session () const

Public Attributes

bool is_if_not_exists
message::Schema schema_message

Private Member Functions

bool validateSchemaOptions ()
bool check (const identifier::Schema &identifier)

Private Attributes

Session & _session
string _db_name

Detailed Description

a class.

To perform various operations related to schema.

Definition at line 41 of file plugin/json_server/ddl/schema.h.

Constructor & Destructor Documentation

◆ Schema()

drizzle_plugin::json_server::Schema::Schema ( Session * in_session,
string db_name )
inline

Constructor.

Parameters
in_sessiona session object.
db_namea schema name string.

Definition at line 50 of file plugin/json_server/ddl/schema.h.

Member Function Documentation

◆ check()

bool Schema::check ( const identifier::Schema & identifier)
private

Checks whether schema exists or not already.

Returns
false Success.
true Failure.

Definition at line 140 of file plugin/json_server/ddl/schema.cc.

◆ createSchema()

bool Schema::createSchema ( )

create a new schema if it not exists.

Returns
false Success.
true Failure.

Definition at line 46 of file plugin/json_server/ddl/schema.cc.

◆ dropSchema()

bool Schema::dropSchema ( )

drop a schema if it exists.

Returns
false Success. @reutrn true Failure.

Definition at line 84 of file plugin/json_server/ddl/schema.cc.

◆ session()

Session & drizzle_plugin::json_server::Schema::session ( ) const
inline

Get a session object.

Returns
a session object.

Definition at line 80 of file plugin/json_server/ddl/schema.h.

◆ validateSchemaOptions()

bool Schema::validateSchemaOptions ( )
private

Validates various schema options.

Returns
false Success.
true Failure.

Definition at line 126 of file plugin/json_server/ddl/schema.cc.

Member Data Documentation

◆ _db_name

string drizzle_plugin::json_server::Schema::_db_name
private

Stores a schema name.

Definition at line 106 of file plugin/json_server/ddl/schema.h.

◆ _session

Session& drizzle_plugin::json_server::Schema::_session
private

Stores a session object.

Definition at line 102 of file plugin/json_server/ddl/schema.h.

◆ is_if_not_exists

bool drizzle_plugin::json_server::Schema::is_if_not_exists

Stores whether schema exist or not.

Definition at line 56 of file plugin/json_server/ddl/schema.h.

◆ schema_message

message::Schema drizzle_plugin::json_server::Schema::schema_message

Stores schema message.

Definition at line 60 of file plugin/json_server/ddl/schema.h.


The documentation for this class was generated from the following files: