foobar2000 SDK  2015-08-03
seekabilizer.h
Go to the documentation of this file.
2 {
3 public:
4  void initialize(t_size p_size);
5  void write(const void * p_buffer,t_size p_bytes);
6  void read(t_size p_backlogdepth,void * p_buffer,t_size p_bytes) const;
7  t_size get_depth() const;
8  void reset();
9  t_size get_max_depth() const;
10 private:
13 };
14 
15 class seekabilizer : public file_readonly {
16 public:
17  void initialize(service_ptr_t<file> p_base,t_size p_buffer_size,abort_callback & p_abort);
18 
19  static void g_seekabilize(service_ptr_t<file> & p_reader,t_size p_buffer_size,abort_callback & p_abort);
20 
21  t_size read(void * p_buffer,t_size p_bytes,abort_callback & p_abort);
23  t_filesize get_position(abort_callback & p_abort);
24  void seek(t_filesize p_position,abort_callback & p_abort);
25  bool can_seek();
26  bool get_content_type(pfc::string_base & p_out);
27  bool is_in_memory();
28  void on_idle(abort_callback & p_abort);
29  t_filetimestamp get_timestamp(abort_callback & p_abort);
30  void reopen(abort_callback & p_abort);
31  bool is_remote();
32 private:
35  t_filesize m_size,m_position,m_position_base;
36 };
t_filesize get_size(HANDLE p_handle)
t_size get_max_depth() const
void seek(HANDLE p_handle, t_sfilesize p_position, file::t_seek_mode p_mode)
pfc::array_t< t_uint8 > m_buffer
Definition: seekabilizer.h:11
void write(const void *p_buffer, t_size p_bytes)
service_ptr_t< file > m_file
Definition: seekabilizer.h:33
seekabilizer_backbuffer m_buffer
Definition: seekabilizer.h:34
size_t t_size
Definition: int_types.h:48
t_uint64 t_filetimestamp
Type used for file timestamp related variables. 64-bit value representing the number of 100-nanosecon...
Definition: filesystem.h:12
t_uint64 t_filesize
Type used for file size related variables.
Definition: filesystem.h:8
void read(t_size p_backlogdepth, void *p_buffer, t_size p_bytes) const
void initialize(t_size p_size)
Definition: seekabilizer.cpp:5
t_size get_depth() const
t_filesize m_size
Definition: seekabilizer.h:35