udf_udf.c

来自「eXtremeDB数据库在Linux平台下的使用源码。内含多个示例程序」· C语言 代码 · 共 48 行

C
48
字号
/* Generated by eXtremeDB Schema Compiler, build 451 * at Thu Dec 14 16:03:16 2006 */#include "udf.h"#include "mcowrap.h"#ifndef _WIN32#include <strings.h>#define STR_CMP strcasecmp#else#include <string.h>#define STR_CMP stricmp#endif/** API for the user-defined index "tudf"*//* object-to-object user-defined compare function */int2  Record_tudf_compare_obj ( Record * handle1, Record * handle2 ){  /* TODO: add your implementation here */  char buf1[11];  char buf2[11];  uint2 len;    Record_name_get(handle1, buf1, 10, &len);  Record_name_get(handle2, buf2, 10, &len);    return STR_CMP(buf1, buf2);}/* object-to-key user-defined compare function */int2  Record_tudf_compare_ext ( Record * handle, void ** key ){  char buf[11];  uint2 len;    Record_name_get(handle, buf, 10, &len);  return STR_CMP(buf, Record_tudf_extkey_name(key));}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?