1
by brian
clean slate |
1 |
/* Copyright (C) 2000-2006 MySQL AB
|
2 |
||
3 |
This program is free software; you can redistribute it and/or modify
|
|
4 |
it under the terms of the GNU General Public License as published by
|
|
5 |
the Free Software Foundation; version 2 of the License.
|
|
6 |
||
7 |
This program is distributed in the hope that it will be useful,
|
|
8 |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
9 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
10 |
GNU General Public License for more details.
|
|
11 |
||
12 |
You should have received a copy of the GNU General Public License
|
|
13 |
along with this program; if not, write to the Free Software
|
|
1802.10.2
by Monty Taylor
Update all of the copyright headers to include the correct address. |
14 |
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
|
1
by brian
clean slate |
15 |
|
16 |
||
2234
by Brian Aker
Mass removal of ifdef/endif in favor of pragma once. |
17 |
#pragma once
|
584.1.15
by Monty Taylor
The mega-patch from hell. Renamed sql_class to session (since that's what it is) and removed it and field and table from common_includes. |
18 |
|
1183.1.2
by Brian Aker
Rename of handler to Cursor. You would not believe how long I have wanted |
19 |
#include <drizzled/cursor.h> |
1241.9.43
by Monty Taylor
Merged trunk. Also renamed thr_lock. Doh. I hate it when I do both. |
20 |
#include <drizzled/thr_lock.h> |
1
by brian
clean slate |
21 |
|
1183.1.2
by Brian Aker
Rename of handler to Cursor. You would not believe how long I have wanted |
22 |
/* class for the the myisam Cursor */
|
1
by brian
clean slate |
23 |
|
992.1.25
by Monty Taylor
Moved myisam to new plugin system. |
24 |
#include <plugin/myisam/myisam.h> |
1
by brian
clean slate |
25 |
|
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
26 |
class ha_myisam: public drizzled::Cursor |
1
by brian
clean slate |
27 |
{
|
28 |
MI_INFO *file; |
|
29 |
char *data_file_name, *index_file_name; |
|
30 |
bool can_enable_indexes; |
|
1220.1.12
by Brian Aker
Small cleanup from something Jay noticed. |
31 |
bool is_ordered; |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
32 |
int repair(drizzled::Session *session, MI_CHECK ¶m, bool optimize); |
1
by brian
clean slate |
33 |
|
34 |
public: |
|
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
35 |
ha_myisam(drizzled::plugin::StorageEngine &engine, |
1869.1.4
by Brian Aker
TableShare is no longer in the house (i.e. we no longer directly have a copy |
36 |
drizzled::Table &table_arg); |
1
by brian
clean slate |
37 |
~ha_myisam() {} |
1253.1.3
by Monty Taylor
MEM_ROOT == memory::Root |
38 |
Cursor *clone(drizzled::memory::Root *mem_root); |
482
by Brian Aker
Remove uint. |
39 |
const char *index_type(uint32_t key_number); |
1491.1.6
by Jay Pipes
Cursor::ha_index_init() -> Cursor::startIndexScan(). Cursor::ha_index_end() -> Cursor::endIndexScan() |
40 |
int doStartIndexScan(uint32_t idx, bool sorted); |
41 |
int doEndIndexScan(); |
|
482
by Brian Aker
Remove uint. |
42 |
uint32_t checksum() const; |
1
by brian
clean slate |
43 |
|
2087.4.2
by Brian Aker
Modify TableIdentifier to fit with the rest of the identifiers. |
44 |
int doOpen(const drizzled::identifier::Table &identifier, int mode, uint32_t test_if_locked); |
1
by brian
clean slate |
45 |
int close(void); |
1491.1.2
by Jay Pipes
Cursor::write_row() -> Cursor::doInsertRecord(). Cursor::ha_write_row() -> Cursor::insertRecord() |
46 |
int doInsertRecord(unsigned char * buf); |
1491.1.3
by Jay Pipes
Cursor::update_row() changed to doUpdateRecord() and updateRecord() |
47 |
int doUpdateRecord(const unsigned char * old_data, unsigned char * new_data); |
1491.1.4
by Jay Pipes
delete_row() is now deleteRecord() and doDeleteRecord() in Cursor |
48 |
int doDeleteRecord(const unsigned char * buf); |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
49 |
int index_read_map(unsigned char *buf, const unsigned char *key, drizzled::key_part_map keypart_map, |
50 |
enum drizzled::ha_rkey_function find_flag); |
|
482
by Brian Aker
Remove uint. |
51 |
int index_read_idx_map(unsigned char *buf, uint32_t index, const unsigned char *key, |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
52 |
drizzled::key_part_map keypart_map, |
53 |
enum drizzled::ha_rkey_function find_flag); |
|
54 |
int index_read_last_map(unsigned char *buf, const unsigned char *key, drizzled::key_part_map keypart_map); |
|
481
by Brian Aker
Remove all of uchar. |
55 |
int index_next(unsigned char * buf); |
56 |
int index_prev(unsigned char * buf); |
|
57 |
int index_first(unsigned char * buf); |
|
58 |
int index_last(unsigned char * buf); |
|
482
by Brian Aker
Remove uint. |
59 |
int index_next_same(unsigned char *buf, const unsigned char *key, uint32_t keylen); |
1491.1.10
by Jay Pipes
ha_rnd_init -> startTableScan, rnd_init -> doStartTableScan, ha_rnd_end -> endTableScan, rnd_end -> doEndTableScan |
60 |
int doStartTableScan(bool scan); |
481
by Brian Aker
Remove all of uchar. |
61 |
int rnd_next(unsigned char *buf); |
62 |
int rnd_pos(unsigned char * buf, unsigned char *pos); |
|
63 |
void position(const unsigned char *record); |
|
1
by brian
clean slate |
64 |
int info(uint); |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
65 |
int extra(enum drizzled::ha_extra_function operation); |
66 |
int extra_opt(enum drizzled::ha_extra_function operation, uint32_t cache_size); |
|
1
by brian
clean slate |
67 |
int reset(void); |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
68 |
int external_lock(drizzled::Session *session, int lock_type); |
1
by brian
clean slate |
69 |
int delete_all_rows(void); |
482
by Brian Aker
Remove uint. |
70 |
int disable_indexes(uint32_t mode); |
71 |
int enable_indexes(uint32_t mode); |
|
1
by brian
clean slate |
72 |
int indexes_are_disabled(void); |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
73 |
void start_bulk_insert(drizzled::ha_rows rows); |
1
by brian
clean slate |
74 |
int end_bulk_insert(); |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
75 |
drizzled::ha_rows records_in_range(uint32_t inx, drizzled::key_range *min_key, drizzled::key_range *max_key); |
1
by brian
clean slate |
76 |
virtual void get_auto_increment(uint64_t offset, uint64_t increment, |
77 |
uint64_t nb_desired_values, |
|
78 |
uint64_t *first_value, |
|
79 |
uint64_t *nb_reserved_values); |
|
80 |
MI_INFO *file_ptr(void) |
|
81 |
{
|
|
82 |
return file; |
|
83 |
}
|
|
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
84 |
int read_range_first(const drizzled::key_range *start_key, const drizzled::key_range *end_key, |
1
by brian
clean slate |
85 |
bool eq_range_arg, bool sorted); |
86 |
int read_range_next(); |
|
1208.2.2
by Brian Aker
Merge Truncate patch. This fixes all of the "half setup" of Truncate. Still |
87 |
int reset_auto_increment(uint64_t value); |
1220.1.12
by Brian Aker
Small cleanup from something Jay noticed. |
88 |
|
89 |
virtual bool isOrdered(void) |
|
90 |
{
|
|
91 |
return false; |
|
92 |
}
|
|
93 |
||
1
by brian
clean slate |
94 |
private: |
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
95 |
drizzled::key_map keys_with_parts; |
1
by brian
clean slate |
96 |
};
|
97 |