Eneboo - Documentación para desarrolladores
src/libmysql_macosx/include/my_handler.h
Ir a la documentación de este archivo.
00001 /* Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
00002 
00003    This library is free software; you can redistribute it and/or
00004    modify it under the terms of the GNU Library General Public
00005    License as published by the Free Software Foundation; either
00006    version 2 of the License, or (at your option) any later version.
00007 
00008    This library is distributed in the hope that it will be useful,
00009    but WITHOUT ANY WARRANTY; without even the implied warranty of
00010    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00011    Library General Public License for more details.
00012 
00013    You should have received a copy of the GNU Library General Public
00014    License along with this library; if not, write to the Free
00015    Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
00016    MA 02111-1307, USA */
00017 
00018 #ifndef _my_handler_h
00019 #define _my_handler_h
00020 
00021 #include "my_global.h"
00022 #include "my_base.h"
00023 #include "m_ctype.h"
00024 #include "myisampack.h"
00025 
00026 typedef struct st_HA_KEYSEG             /* Key-portion */
00027 {
00028   uint8  type;                          /* Type of key (for sort) */
00029   uint8  language;
00030   uint8  null_bit;                      /* bitmask to test for NULL */
00031   uint8  bit_start,bit_end;             /* if bit field */
00032   uint16 flag;
00033   uint16 length;                        /* Keylength */
00034   uint32 start;                         /* Start of key in record */
00035   uint32 null_pos;                      /* position to NULL indicator */
00036   CHARSET_INFO *charset;
00037 } HA_KEYSEG;
00038 
00039 #define get_key_length(length,key) \
00040 { if ((uchar) *(key) != 255) \
00041     length= (uint) (uchar) *((key)++); \
00042   else \
00043   { length=mi_uint2korr((key)+1); (key)+=3; } \
00044 }
00045 
00046 #define get_key_length_rdonly(length,key) \
00047 { if ((uchar) *(key) != 255) \
00048     length= ((uint) (uchar) *((key))); \
00049   else \
00050   { length=mi_uint2korr((key)+1); } \
00051 }
00052 
00053 #define get_key_pack_length(length,length_pack,key) \
00054 { if ((uchar) *(key) != 255) \
00055   { length= (uint) (uchar) *((key)++); length_pack=1; }\
00056   else \
00057   { length=mi_uint2korr((key)+1); (key)+=3; length_pack=3; } \
00058 }
00059 
00060 extern int mi_compare_text(CHARSET_INFO *, uchar *, uint, uchar *, uint ,
00061                            my_bool, my_bool);
00062 extern int ha_key_cmp(register HA_KEYSEG *keyseg, register uchar *a,
00063                       register uchar *b, uint key_length, uint nextflag,
00064                       uint *diff_pos);
00065 
00066 #endif /* _my_handler_h */
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'