~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/internal/iocache.h

  • Committer: Brian Aker
  • Date: 2011-02-22 06:12:02 UTC
  • mfrom: (2190.1.6 drizzle-build)
  • Revision ID: brian@tangent.org-20110222061202-k03czxykqy4x9hjs
List update, header fixes, multiple symbols, and David deletes some code.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
#ifndef DRIZZLED_INTERNAL_IOCACHE_H
22
22
#define DRIZZLED_INTERNAL_IOCACHE_H
23
23
 
24
 
#include "drizzled/internal/my_sys.h"
 
24
#include <drizzled/internal/my_sys.h>
25
25
 
26
26
namespace drizzled
27
27
{
175
175
 
176
176
  ~st_io_cache()
177
177
  { }
 
178
 
 
179
  void close_cached_file();
 
180
  bool real_open_cached_file();
 
181
  int end_io_cache();
 
182
  int init_io_cache(int file, size_t cachesize,
 
183
                    enum cache_type type, my_off_t seek_offset,
 
184
                    bool use_async_io, myf cache_myflags);
 
185
  void init_functions();
 
186
 
 
187
  bool reinit_io_cache(enum cache_type type_arg,
 
188
                       my_off_t seek_offset,
 
189
                       bool use_async_io,
 
190
                       bool clear_cache);
 
191
  void setup_io_cache();
 
192
  bool open_cached_file(const char *dir,
 
193
                        const char *prefix, size_t cache_size,
 
194
                        myf cache_myflags);
 
195
 
178
196
};
179
197
 
180
198
typedef struct st_io_cache IO_CACHE;    /* Used when cacheing files */
181
199
 
182
 
extern int init_io_cache(IO_CACHE *info,int file,size_t cachesize,
183
 
                         enum cache_type type,my_off_t seek_offset,
184
 
                         bool use_async_io, myf cache_myflags);
185
 
extern bool reinit_io_cache(IO_CACHE *info,enum cache_type type,
186
 
                            my_off_t seek_offset,bool use_async_io,
187
 
                            bool clear_cache);
188
 
extern void setup_io_cache(IO_CACHE* info);
189
 
extern int _my_b_get(IO_CACHE *info);
190
 
extern int _my_b_async_read(IO_CACHE *info,unsigned char *Buffer,size_t Count);
 
200
extern int _my_b_get(st_io_cache *info);
 
201
extern int _my_b_async_read(st_io_cache *info,unsigned char *Buffer,size_t Count);
191
202
 
192
 
extern int my_block_write(IO_CACHE *info, const unsigned char *Buffer,
 
203
extern int my_block_write(st_io_cache *info, const unsigned char *Buffer,
193
204
                          size_t Count, my_off_t pos);
194
 
extern int my_b_flush_io_cache(IO_CACHE *info, int need_append_buffer_lock);
 
205
extern int my_b_flush_io_cache(st_io_cache *info, int need_append_buffer_lock);
195
206
 
196
207
#define flush_io_cache(info) my_b_flush_io_cache((info),1)
197
208
 
198
 
extern int end_io_cache(IO_CACHE *info);
199
 
extern bool open_cached_file(IO_CACHE *cache,const char *dir,
200
 
                             const char *prefix, size_t cache_size,
201
 
                             myf cache_myflags);
202
 
extern bool real_open_cached_file(IO_CACHE *cache);
203
 
extern void close_cached_file(IO_CACHE *cache);
204
 
 
205
209
} /* namespace internal */
206
210
} /* namespace drizzled */
207
211