~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_base.h

  • Committer: Monty Taylor
  • Date: 2010-06-15 16:57:34 UTC
  • Revision ID: mordred@inaugust.com-20100615165734-qwi2zijn86510fiw
Added include.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
2
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
3
3
 *
4
 
 *  Copyright (C) 2008 Sun Microsystems, Inc.
 
4
 *  Copyright (C) 2008 Sun Microsystems
5
5
 *
6
6
 *  This program is free software; you can redistribute it and/or modify
7
7
 *  it under the terms of the GNU General Public License as published by
17
17
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
18
18
 */
19
19
 
20
 
 
21
 
 
22
20
#ifndef DRIZZLED_SQL_BASE_H
23
21
#define DRIZZLED_SQL_BASE_H
24
22
 
25
23
#include <drizzled/table.h>
26
 
#include <drizzled/table_list.h>
27
 
#include <drizzled/table/concurrent.h>
28
 
 
29
 
#include <drizzled/visibility.h>
30
24
 
31
25
namespace drizzled
32
26
{
37
31
bool table_cache_init(void);
38
32
uint32_t cached_open_tables(void);
39
33
uint32_t cached_table_definitions(void);
40
 
 
41
 
table::Cache &get_open_cache();
42
 
 
43
 
DRIZZLED_API void kill_drizzle(void);
 
34
HASH *get_open_cache();
 
35
 
 
36
void kill_drizzle(void);
44
37
 
45
38
/* sql_base.cc */
46
39
void set_item_name(Item *item,char *pos,uint32_t length);
58
51
                               Item *default_value, Item *on_update_value,
59
52
                               LEX_STRING *comment, char *change,
60
53
                               List<String> *interval_list, CHARSET_INFO *cs);
 
54
void store_position_for_column(const char *name);
61
55
bool push_new_name_resolution_context(Session *session,
62
56
                                      TableList *left_op,
63
57
                                      TableList *right_op);
101
95
                          enum_resolution_type *resolution);
102
96
bool insert_fields(Session *session, Name_resolution_context *context,
103
97
                   const char *db_name, const char *table_name,
104
 
                   List<Item>::iterator *it, bool any_privileges);
 
98
                   List_iterator<Item> *it, bool any_privileges);
105
99
bool setup_tables(Session *session, Name_resolution_context *context,
106
100
                  List<TableList> *from_clause, TableList *tables,
107
101
                  TableList **leaves, bool select_insert);
136
130
                               const char *table_name);
137
131
TableList *unique_table(TableList *table, TableList *table_list,
138
132
                        bool check_alias= false);
 
133
void remove_db_from_cache(SchemaIdentifier &schema_identifier);
139
134
 
140
 
/* bits for last argument to table::Cache::singleton().removeTable() */
 
135
/* bits for last argument to remove_table_from_cache() */
141
136
#define RTFC_NO_FLAG                0x0000
142
137
#define RTFC_OWNED_BY_Session_FLAG      0x0001
143
138
#define RTFC_WAIT_OTHER_THREAD_FLAG 0x0002
144
139
#define RTFC_CHECK_KILLED_FLAG      0x0004
 
140
bool remove_table_from_cache(Session *session, TableIdentifier &identifier, uint32_t flags);
145
141
 
146
142
void mem_alloc_error(size_t size);
147
143
 
155
151
                            db_name, table_name);
156
152
}
157
153
 
158
 
bool drizzle_rm_tmp_tables();
159
 
 
160
154
} /* namespace drizzled */
161
155
 
162
156
#endif /* DRIZZLED_SQL_BASE_H */