#include <seekabilizer.h>
Definition at line 15 of file seekabilizer.h.
bool seekabilizer::can_seek |
( |
| ) |
|
Definition at line 87 of file seekabilizer.cpp.
88 if (p_reader.
is_valid() && p_reader->is_remote() && p_buffer_size > 0) {
90 instance->initialize(p_reader,p_buffer_size,p_abort);
Template implementing reference-counting features of service_base. Intended for dynamic instantiation...
Autopointer class to be used with all services. Manages reference counter calls behind-the-scenes.
t_filetimestamp seekabilizer::get_timestamp |
( |
abort_callback & |
p_abort | ) |
|
Definition at line 80 of file seekabilizer.cpp.
t_filesize m_position_base
service_ptr_t< file > m_file
seekabilizer_backbuffer m_buffer
void initialize(t_size p_size)
bool seekabilizer::is_in_memory |
( |
| ) |
|
bool seekabilizer::is_remote |
( |
| ) |
|
Definition at line 95 of file seekabilizer.cpp.
103 m_file->seek(target,p_abort);
109 enum {tempsize = 1024};
113 bytes_read =
m_file->read(temp,delta,p_abort);
117 if (bytes_read < delta) {
129 t_size delta = pfc::min_t<t_size>(backread_depth,p_bytes-done);
139 bytes_read =
m_file->read(targetptr+done,p_bytes-done,p_abort);
t_size get_max_depth() const
t_filesize m_position_base
void write(const void *p_buffer, t_size p_bytes)
service_ptr_t< file > m_file
seekabilizer_backbuffer m_buffer
t_uint64 t_filesize
Type used for file size related variables.
void read(t_size p_backlogdepth, void *p_buffer, t_size p_bytes) const
Definition at line 206 of file seekabilizer.cpp.
t_filesize m_position_base
service_ptr_t< file > m_file
seekabilizer_backbuffer m_buffer
void seek(t_filesize p_position, abort_callback &p_abort)
void seekabilizer::seek |
( |
t_filesize |
p_position, |
|
|
abort_callback & |
p_abort |
|
) |
| |
Definition at line 161 of file seekabilizer.cpp.
169 if (p_position < lowest) {
175 if (target > delta) target -= delta;
177 m_file->seek(target,p_abort);
t_size get_max_depth() const
t_filesize m_position_base
static const t_filesize filesize_invalid
Invalid/unknown file size constant. Also see: t_filesize.
service_ptr_t< file > m_file
seekabilizer_backbuffer m_buffer
t_uint64 t_filesize
Type used for file size related variables.
t_filesize seekabilizer::m_position |
|
private |
t_filesize seekabilizer::m_position_base |
|
private |
t_filesize seekabilizer::m_size |
|
private |
The documentation for this class was generated from the following files: