Public Types | Public Member Functions | Static Public Member Functions | Protected Attributes | Private Member Functions

c_file_ptr_buf Class Reference

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

Inheritance diagram for c_file_ptr_buf:
Inheritance graph
[legend]
Collaboration diagram for c_file_ptr_buf:
Collaboration graph
[legend]

List of all members.

Public Types

typedef int(* close_fcn )(FILE *)
typedef int int_type

Public Member Functions

 c_file_ptr_buf (FILE *f_arg, close_fcn cf_arg=file_close)
 ~c_file_ptr_buf (void)
int buf_close (void)
void clear (void)
int file_number () const
int flush (void)
int_type overflow (int_type)
int_type pbackfail (int_type)
int seek (long 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)
FILE * stdiofile (void)
int sync (void)
long tell (void)
int_type uflow (void)
int_type underflow (void)
std::streamsize xsgetn (char *, std::streamsize)
std::streamsize xsputn (const char *, std::streamsize)

Static Public Member Functions

static int file_close (FILE *f)

Protected Attributes

close_fcn cf
FILE * f

Private Member Functions

 c_file_ptr_buf (const c_file_ptr_buf &)
c_file_ptr_bufoperator= (const c_file_ptr_buf &)
int_type underflow_common (bool)

Detailed Description

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


Member Typedef Documentation

typedef int(* c_file_ptr_buf::close_fcn)(FILE *)

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

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


Constructor & Destructor Documentation

c_file_ptr_buf::c_file_ptr_buf ( FILE *  f_arg,
close_fcn  cf_arg = file_close 
) [inline]

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

c_file_ptr_buf::~c_file_ptr_buf ( void   ) 

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

References buf_close().

c_file_ptr_buf::c_file_ptr_buf ( const c_file_ptr_buf  )  [private]

Member Function Documentation

int c_file_ptr_buf::buf_close ( void   ) 

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

References cf, f, and flush().

Referenced by ~c_file_ptr_buf().

void c_file_ptr_buf::clear ( void   )  [inline]

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

References f.

int c_file_ptr_buf::file_close ( FILE *  f  )  [static]

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

int c_file_ptr_buf::file_number (  )  const [inline]

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

References f.

int c_file_ptr_buf::flush ( void   ) 

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

References f.

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

c_file_ptr_buf& c_file_ptr_buf::operator= ( const c_file_ptr_buf  )  [private]
c_file_ptr_buf::int_type c_file_ptr_buf::overflow ( int_type  c  ) 

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

References f, and flush().

c_file_ptr_buf::int_type c_file_ptr_buf::pbackfail ( int_type  c  ) 

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

References f.

int c_file_ptr_buf::seek ( long  offset,
int  origin 
)

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

References f.

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

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

References f, and seekdir_to_whence().

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

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

References f, and SEEK_SET.

FILE* c_file_ptr_buf::stdiofile ( void   )  [inline]

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

References f.

int c_file_ptr_buf::sync ( void   ) 

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

References flush().

long c_file_ptr_buf::tell ( void   ) 

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

References f.

int_type c_file_ptr_buf::uflow ( void   )  [inline]

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

int_type c_file_ptr_buf::underflow ( void   )  [inline]

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

c_file_ptr_buf::int_type c_file_ptr_buf::underflow_common ( bool  bump  )  [private]

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

References f.

std::streamsize c_file_ptr_buf::xsgetn ( char s,
std::streamsize  n 
)

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

References f.

std::streamsize c_file_ptr_buf::xsputn ( const char s,
std::streamsize  n 
)

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

References f.


Member Data Documentation

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

Referenced by buf_close().

FILE* c_file_ptr_buf::f [protected]

The documentation for this class was generated from the following files:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines