~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/key.h

  • Committer: Monty Taylor
  • Date: 2010-04-22 02:46:23 UTC
  • mto: (1497.3.4 enable-dtrace)
  • mto: This revision was merged to the branch mainline in revision 1527.
  • Revision ID: mordred@inaugust.com-20100422024623-4urw8fi8eraci08p
Don't overwrite the pandora_vc_revinfo file if we don't have new
authoratative information.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
#define DRIZZLED_KEY_H
23
23
 
24
24
#include <string>
25
 
#include <boost/dynamic_bitset.hpp>
26
25
 
27
26
#include "drizzled/memory/sql_alloc.h"
28
27
#include "drizzled/key_part_spec.h"
37
36
namespace memory { class Root; }
38
37
 
39
38
class Item;
 
39
class MyBitmap;
40
40
 
41
41
class Key :public memory::SqlAlloc {
42
42
public:
69
69
};
70
70
 
71
71
 
72
 
int find_ref_key(KeyInfo *key, uint32_t key_count, unsigned char *record, Field *field,
 
72
int find_ref_key(KEY *key, uint32_t key_count, unsigned char *record, Field *field,
73
73
                 uint32_t *key_length, uint32_t *keypart);
74
74
/**
75
75
  Copy part of a record that forms a key or key prefix to a buffer.
86
86
  @param key_length  specifies length of all keyparts that will be copied
87
87
*/
88
88
 
89
 
void key_copy(unsigned char *to_key, unsigned char *from_record, KeyInfo *key_info, uint32_t key_length);
 
89
void key_copy(unsigned char *to_key, unsigned char *from_record, KEY *key_info, uint32_t key_length);
90
90
void key_copy(std::basic_string<unsigned char> &to_key,
91
 
              unsigned char *from_record, KeyInfo *key_info, uint32_t key_length);
92
 
void key_restore(unsigned char *to_record, unsigned char *from_key, KeyInfo *key_info,
 
91
              unsigned char *from_record, KEY *key_info, uint32_t key_length);
 
92
void key_restore(unsigned char *to_record, unsigned char *from_key, KEY *key_info,
93
93
                 uint16_t key_length);
94
 
void key_zero_nulls(unsigned char *tuple, KeyInfo *key_info);
 
94
void key_zero_nulls(unsigned char *tuple, KEY *key_info);
95
95
bool key_cmp_if_same(Table *form,const unsigned char *key,uint32_t index,uint32_t key_length);
96
96
void key_unpack(String *to,Table *form,uint32_t index);
97
 
bool is_key_used(Table *table, uint32_t idx, const boost::dynamic_bitset<>& fields);
98
 
int key_cmp(KeyPartInfo *key_part, const unsigned char *key, uint32_t key_length);
 
97
bool is_key_used(Table *table, uint32_t idx, const MyBitmap *fields);
 
98
int key_cmp(KEY_PART_INFO *key_part, const unsigned char *key, uint32_t key_length);
99
99
 
100
100
} /* namespace drizzled */
101
101