~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/info_schema/info_schema_methods.h

  • Committer: devananda
  • Date: 2009-06-30 14:27:54 UTC
  • mfrom: (1030.2.4 trunk)
  • mto: (1093.1.7 captain)
  • mto: This revision was merged to the branch mainline in revision 1095.
  • Revision ID: devananda.vdv@gmail.com-20090630142754-vm9w374yxkf1pikc
mergeĀ fromĀ lp

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
 
2
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
 
3
 *
 
4
 *  Copyright (C) 2009 Sun Microsystems
 
5
 *
 
6
 *  This program is free software; you can redistribute it and/or modify
 
7
 *  it under the terms of the GNU General Public License as published by
 
8
 *  the Free Software Foundation; either version 2 of the License, or
 
9
 *  (at your option) any later version.
 
10
 *
 
11
 *  This program is distributed in the hope that it will be useful,
 
12
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
14
 *  GNU General Public License for more details.
 
15
 *
 
16
 *  You should have received a copy of the GNU General Public License
 
17
 *  along with this program; if not, write to the Free Software
 
18
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 
19
 */
 
20
 
 
21
#ifndef DRIZZLED_INFO_SCHEMA_METHODS_H
 
22
#define DRIZZLED_INFO_SCHEMA_METHODS_H
 
23
 
 
24
#include "drizzled/info_schema.h"
 
25
 
 
26
/**
 
27
 * @class
 
28
 *   CharSetISMethods
 
29
 * @brief
 
30
 *   Class which implements any methods that the 
 
31
 *   CHARACTER_SET I_S table needs besides the default
 
32
 *   methods.
 
33
 */
 
34
class CharSetISMethods : public InfoSchemaMethods
 
35
{
 
36
public:
 
37
  virtual int fillTable(Session *session, 
 
38
                        TableList *tables,
 
39
                        COND *cond);
 
40
  virtual int oldFormat(Session *session, InfoSchemaTable *schema_table) const;
 
41
};
 
42
 
 
43
/**
 
44
 * @class
 
45
 *   CollationISMethods
 
46
 * @brief
 
47
 *   Class which implements any methods that the Collations
 
48
 *   I_S table needs besides the default methods
 
49
 */
 
50
class CollationISMethods : public InfoSchemaMethods
 
51
{
 
52
public:
 
53
  virtual int fillTable(Session *session,
 
54
                        TableList *tables,
 
55
                        COND *cond);
 
56
};
 
57
 
 
58
/**
 
59
 * @class
 
60
 *   CollCharISMethods
 
61
 * @brief
 
62
 *   Class which implements any methods that the collation char set
 
63
 *   I_S table needs besides the default methods
 
64
 */
 
65
class CollCharISMethods : public InfoSchemaMethods
 
66
{
 
67
public:
 
68
  virtual int fillTable(Session *session,
 
69
                        TableList *tables,
 
70
                        COND *cond);
 
71
};
 
72
 
 
73
/**
 
74
 * @class
 
75
 *   KeyColUsageISMethods
 
76
 * @brief
 
77
 *   Class which implements any methods that the key column usage
 
78
 *   I_S table needs besides the default methods
 
79
 */
 
80
class KeyColUsageISMethods : public InfoSchemaMethods
 
81
{
 
82
public:
 
83
  virtual int processTable(Session *session, TableList *tables,
 
84
                           Table *table, bool res, LEX_STRING *db_name,
 
85
                           LEX_STRING *table_name) const;
 
86
};
 
87
 
 
88
/**
 
89
 * @class
 
90
 *   PluginsISMethods
 
91
 * @brief
 
92
 *   Class which implements any methods that the PLUGINS
 
93
 *   I_S table needs besides the default methods
 
94
 */
 
95
class PluginsISMethods : public InfoSchemaMethods
 
96
{
 
97
public:
 
98
  virtual int fillTable(Session *session,
 
99
                        TableList *tables,
 
100
                        COND *cond);
 
101
};
 
102
 
 
103
/**
 
104
 * @class
 
105
 *   ProcessListISMethods
 
106
 * @brief
 
107
 *   Class which implements any methods that the PROCESSLIST
 
108
 *   I_S table needs besides the default methods
 
109
 */
 
110
class ProcessListISMethods : public InfoSchemaMethods
 
111
{
 
112
public:
 
113
  virtual int fillTable(Session *session,
 
114
                        TableList *tables,
 
115
                        COND *cond);
 
116
};
 
117
 
 
118
/**
 
119
 * @class
 
120
 *   RefConstraintISMethods
 
121
 * @brief
 
122
 *   Class which implements any methods that the REFERENTIAL_CONSTRAINTS
 
123
 *   I_S table needs besides the default methods
 
124
 */
 
125
class RefConstraintsISMethods : public InfoSchemaMethods
 
126
{
 
127
public:
 
128
  /**
 
129
   * Fill and store records into I_S.referential_constraints table
 
130
   *
 
131
   * @param[in] session   thread handle
 
132
   * @param[in] tables    table list struct(processed table)
 
133
   * @param[in] table     I_S table
 
134
   * @param[in] res       1 means the error during opening of the processed table
 
135
   *                      0 means processed table is opened without error
 
136
   * @param[in] base_name db name
 
137
   * @param[in] file_name table name
 
138
   *
 
139
   * @return 0 on success; 1 on failure
 
140
   */
 
141
  virtual int processTable(Session *session, TableList *tables,
 
142
                           Table *table, bool res, LEX_STRING *db_name,
 
143
                           LEX_STRING *table_name) const;
 
144
};
 
145
 
 
146
/**
 
147
 * @class
 
148
 *   TabConstraintsISMethods
 
149
 * @brief
 
150
 *   Class which implements any methods that the TABLE_CONSTRAINTS
 
151
 *   I_S table needs besides the default methods
 
152
 */
 
153
class TabConstraintsISMethods : public InfoSchemaMethods
 
154
{
 
155
public:
 
156
  virtual int processTable(Session *session, TableList *tables,
 
157
                           Table *table, bool res, LEX_STRING *db_name,
 
158
                           LEX_STRING *table_name) const;
 
159
};
 
160
 
 
161
#endif /* DRIZZLE_INFO_SCHEMA_METHODS_H */