Jpp 19.3.0-rc.1
the software that should make you happy
Loading...
Searching...
No Matches
gzstreambase Class Reference

#include <gzstream.h>

Inheritance diagram for gzstreambase:
igzstream ogzstream JLANG::JGZFileReader< T > JLANG::JGZFileWriter< T >

Public Member Functions

 gzstreambase ()
 
 gzstreambase (const char *name, int mode)
 
 ~gzstreambase ()
 
void open (const char *name, int open_mode)
 
void close ()
 
gzstreambufrdbuf ()
 
bool is_open () const
 

Protected Attributes

gzstreambuf buf
 

Detailed Description

Definition at line 167 of file gzstream.h.

Constructor & Destructor Documentation

◆ gzstreambase() [1/2]

gzstreambase::gzstreambase ( )
inline

Definition at line 172 of file gzstream.h.

172{ init(&buf); }
gzstreambuf buf
Definition gzstream.h:169

◆ gzstreambase() [2/2]

gzstreambase::gzstreambase ( const char * name,
int mode )
inline

Definition at line 173 of file gzstream.h.

173 {
174 init( &buf);
175 open( name, mode);
176 }
void open(const char *name, int open_mode)
Definition gzstream.h:180

◆ ~gzstreambase()

gzstreambase::~gzstreambase ( )
inline

Definition at line 177 of file gzstream.h.

177 {
178 buf.close();
179 }
gzstreambuf * close()
Definition gzstream.h:108

Member Function Documentation

◆ open()

void gzstreambase::open ( const char * name,
int open_mode )
inline

Definition at line 180 of file gzstream.h.

180 {
181 if ( ! buf.open( name, open_mode))
182 clear( rdstate() | std::ios::badbit);
183 }
gzstreambuf * open(const char *name, int open_mode)
Definition gzstream.h:82

◆ close()

void gzstreambase::close ( )
inline

Definition at line 185 of file gzstream.h.

185 {
186 if ( buf.is_open()) {
187 if ( ! buf.close())
188 clear( rdstate() | std::ios::badbit );
189 else
190 clear();
191 }
192 }
int is_open() const
Definition gzstream.h:79

◆ rdbuf()

gzstreambuf * gzstreambase::rdbuf ( )
inline

Definition at line 193 of file gzstream.h.

193{ return &buf; }

◆ is_open()

bool gzstreambase::is_open ( ) const
inline

Definition at line 194 of file gzstream.h.

194{ return buf.is_open(); }

Member Data Documentation

◆ buf

gzstreambuf gzstreambase::buf
protected

Definition at line 169 of file gzstream.h.


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