diff options
author | serg@janus.mylan <> | 2007-01-29 10:40:26 +0100 |
---|---|---|
committer | serg@janus.mylan <> | 2007-01-29 10:40:26 +0100 |
commit | a07fd5fa8ff4b5b98fbe79b8e7301d5effaf9c2f (patch) | |
tree | f14bd08181ddd81d2a41f06d9bf0f11d6edf53b5 /storage/example | |
parent | 045d7047095be717c94fd823252d513dad8c4478 (diff) | |
download | mariadb-git-a07fd5fa8ff4b5b98fbe79b8e7301d5effaf9c2f.tar.gz |
WL#3700: Handler API change: all index search methods - that is,
index_read(), index_read_idx(), index_read_last(), and
records_in_range() - instead of 'uint keylen' argument take
'ulonglong keypart_map', a bitmap showing which keyparts are
present in the key value.
Fallback method is provided for handlers that are lagging behind.
Diffstat (limited to 'storage/example')
-rw-r--r-- | storage/example/ha_example.cc | 5 | ||||
-rw-r--r-- | storage/example/ha_example.h | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/storage/example/ha_example.cc b/storage/example/ha_example.cc index 12ca91f0a6f..65554eb1252 100644 --- a/storage/example/ha_example.cc +++ b/storage/example/ha_example.cc @@ -90,14 +90,13 @@ static handler *example_create_handler(handlerton *hton, TABLE_SHARE *table, MEM_ROOT *mem_root); -static int example_init_func(); +static int example_init_func(void *); handlerton *example_hton; /* Variables for example share methods */ static HASH example_open_tables; ///< Hash used to track the number of open tables; variable for example share methods pthread_mutex_t example_mutex; ///< This is the mutex used to init the hash; variable for example share methods -static int example_init= 0; ///< This variable is used to check the init state of hash; variable for example share methods /** @brief Function we use in the creation of our hash to get key. @@ -372,7 +371,7 @@ int ha_example::delete_row(const byte * buf) index. */ int ha_example::index_read(byte * buf, const byte * key, - uint key_len __attribute__((unused)), + ulonglong keypart_map __attribute__((unused)), enum ha_rkey_function find_flag __attribute__((unused))) { diff --git a/storage/example/ha_example.h b/storage/example/ha_example.h index 9b912514887..ee60b412974 100644 --- a/storage/example/ha_example.h +++ b/storage/example/ha_example.h @@ -191,7 +191,7 @@ public: skip it and and MySQL will treat it as not implemented. */ int index_read(byte * buf, const byte * key, - uint key_len, enum ha_rkey_function find_flag); + ulonglong keypart_map, enum ha_rkey_function find_flag); /** @brief We implement this in ha_example.cc. It's not an obligatory method; |