D.S

dev.mysql.com

MySQL: storage/innobase/ha/ha0storage.cc File Reference

MySQL: storage/innobase/ha/ha0storage.cc File Reference MySQL  8.0.0 Source Code Documentation Main Page Related Pages Modules Namespaces Classes Files File List File Members Macros | Functions ha0storage.cc File Reference Hash storage. More... #include " ha_prototypes.h " #include " ha0storage.h " #include " hash0hash.h " #include " mem0mem.h " #include " ut0rnd.h " Macros #define  IS_FOUND    node->data_len == data_len && memcmp(node->data, data, data_len) == 0   Functions static const void *  ha_storage_get (ha_storage_t *storage, const void *data, ulint data_len)   Retrieves a data from a storage. More...   const void *  ha_storage_put_memlim (ha_storage_t *storage, const void *data, ulint data_len, ulint memlim)   Copies data into the storage and returns a pointer to the copy. More...   Detailed Description Hash storage. Provides a data structure that stores chunks of data in its own storage, avoiding duplicates. Created September 22, 2007 Vasil Dimov Macro Definition Documentation #define IS_FOUND   node->data_len == data_len && memcmp(node->data, data, data_len) == 0 Function Documentation static const void* ha_storage_get ( ha_storage_t *  storage, const void *  data, ulint  data_len  ) static Retrieves a data from a storage. If it is present, a pointer to the stored copy of data is returned, otherwise NULL is returned. Parameters storage in: hash storage data in: data to check for data_len in: data length const void* ha_storage_put_memlim ( ha_storage_t *  storage, const void *  data, ulint  data_len, ulint  memlim  ) Copies data into the storage and returns a pointer to the copy. If the same data chunk is already present, then pointer to it is returned. Data chunks are considered to be equal if len1 == len2 and memcmp(data1, data2, len1) == 0. If "data" is not present (and thus data_len bytes need to be allocated) and the size of storage is going to become more than "memlim" then "data" is not added and NULL is returned. To disable this behavior "memlim" can be set to 0, which stands for "no limit". Parameters storage in/out: hash storage data in: data to store data_len in: data length memlim in: memory limit to obey storage innobase ha ha0storage.cc Generated by 1.8.11