GNU Octave  9.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
c_zfile_ptr_buf Class Reference

#include "c-file-ptr-stream.h"

Inheritance diagram for c_zfile_ptr_buf:

Public Types

typedef int(* close_fcn) (gzFile)
 
typedef std::streambuf::int_type int_type
 

Public Member Functions

 c_zfile_ptr_buf ()=delete
 
 c_zfile_ptr_buf (gzFile f, close_fcn cf=file_close)
 
 ~c_zfile_ptr_buf ()
 
int buf_close ()
 
void clear ()
 
int file_number () const
 
int flush ()
 
int_type overflow (int_type)
 
int_type pbackfail (int_type)
 
int seek (off_t offset, int origin)
 
std::streampos seekoff (std::streamoff, std::ios::seekdir, std::ios::openmode=std::ios::in|std::ios::out)
 
std::streampos seekpos (std::streampos, std::ios::openmode=std::ios::in|std::ios::out)
 
gzFile stdiofile ()
 
int sync ()
 
off_t tell ()
 
int_type uflow ()
 
int_type underflow ()
 
std::streamsize xsgetn (char *, std::streamsize)
 
std::streamsize xsputn (const char *, std::streamsize)
 

Static Public Member Functions

static int file_close (gzFile m_f)
 

Protected Attributes

close_fcn m_cf
 
gzFile m_f
 

Detailed Description

Definition at line 151 of file c-file-ptr-stream.h.

Member Typedef Documentation

◆ close_fcn

typedef int(* c_zfile_ptr_buf::close_fcn) (gzFile)

Definition at line 158 of file c-file-ptr-stream.h.

◆ int_type

typedef std::streambuf::int_type c_zfile_ptr_buf::int_type

Definition at line 156 of file c-file-ptr-stream.h.

Constructor & Destructor Documentation

◆ c_zfile_ptr_buf() [1/2]

c_zfile_ptr_buf::c_zfile_ptr_buf ( )
delete

◆ c_zfile_ptr_buf() [2/2]

c_zfile_ptr_buf::c_zfile_ptr_buf ( gzFile  f,
close_fcn  cf = file_close 
)
inline

Definition at line 164 of file c-file-ptr-stream.h.

◆ ~c_zfile_ptr_buf()

c_zfile_ptr_buf::~c_zfile_ptr_buf ( )

Definition at line 194 of file c-file-ptr-stream.cc.

References buf_close().

Member Function Documentation

◆ buf_close()

int c_zfile_ptr_buf::buf_close ( )

Definition at line 284 of file c-file-ptr-stream.cc.

References flush(), m_cf, and m_f.

Referenced by ~c_zfile_ptr_buf().

◆ clear()

void c_zfile_ptr_buf::clear ( )
inline

Definition at line 203 of file c-file-ptr-stream.h.

◆ file_close()

static int c_zfile_ptr_buf::file_close ( gzFile  m_f)
inlinestatic

Definition at line 205 of file c-file-ptr-stream.h.

◆ file_number()

int c_zfile_ptr_buf::file_number ( ) const
inline

Definition at line 196 of file c-file-ptr-stream.h.

◆ flush()

int c_zfile_ptr_buf::flush ( )

Definition at line 274 of file c-file-ptr-stream.cc.

References m_f.

Referenced by buf_close(), overflow(), and sync().

◆ overflow()

c_zfile_ptr_buf::int_type c_zfile_ptr_buf::overflow ( int_type  c)

Definition at line 202 of file c-file-ptr-stream.cc.

References flush(), and m_f.

◆ pbackfail()

c_zfile_ptr_buf::int_type c_zfile_ptr_buf::pbackfail ( int_type  c)

Definition at line 227 of file c-file-ptr-stream.cc.

References m_f.

◆ seek()

int c_zfile_ptr_buf::seek ( off_t  offset,
int  origin 
)
inline

Definition at line 198 of file c-file-ptr-stream.h.

◆ seekoff()

std::streampos c_zfile_ptr_buf::seekoff ( std::streamoff  ,
std::ios::seekdir  ,
std::ios::openmode  = std::ios::in | std::ios::out 
)

Definition at line 252 of file c-file-ptr-stream.cc.

◆ seekpos()

std::streampos c_zfile_ptr_buf::seekpos ( std::streampos  ,
std::ios::openmode  = std::ios::in | std::ios::out 
)

Definition at line 260 of file c-file-ptr-stream.cc.

◆ stdiofile()

gzFile c_zfile_ptr_buf::stdiofile ( )
inline

Definition at line 160 of file c-file-ptr-stream.h.

◆ sync()

int c_zfile_ptr_buf::sync ( )

Definition at line 266 of file c-file-ptr-stream.cc.

References flush().

◆ tell()

off_t c_zfile_ptr_buf::tell ( )
inline

Definition at line 201 of file c-file-ptr-stream.h.

◆ uflow()

int_type c_zfile_ptr_buf::uflow ( )
inline

Definition at line 176 of file c-file-ptr-stream.h.

◆ underflow()

int_type c_zfile_ptr_buf::underflow ( )
inline

Definition at line 174 of file c-file-ptr-stream.h.

◆ xsgetn()

std::streamsize c_zfile_ptr_buf::xsgetn ( char *  s,
std::streamsize  n 
)

Definition at line 243 of file c-file-ptr-stream.cc.

References m_f, and n.

◆ xsputn()

std::streamsize c_zfile_ptr_buf::xsputn ( const char *  s,
std::streamsize  n 
)

Definition at line 234 of file c-file-ptr-stream.cc.

References m_f, and n.

Member Data Documentation

◆ m_cf

close_fcn c_zfile_ptr_buf::m_cf
protected

Definition at line 211 of file c-file-ptr-stream.h.

Referenced by buf_close().

◆ m_f

gzFile c_zfile_ptr_buf::m_f
protected

Definition at line 209 of file c-file-ptr-stream.h.

Referenced by buf_close(), flush(), overflow(), pbackfail(), xsgetn(), and xsputn().


The documentation for this class was generated from the following files: