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

#include "oct-iostrm.h"

Inheritance diagram for base_iostream:
base_stream istream ostream

Public Member Functions

 base_iostream (const std::string &n="", std::ios::openmode m=std::ios::in|std::ios::out, mach_info::float_format ff=mach_info::native_float_format())
 
bool eof () const
 
std::string name () const
 
int seek (off_t offset, int origin)
 
off_t tell ()
 
- Public Member Functions inherited from base_stream
 base_stream (std::ios::openmode arg_md=std::ios::in|std::ios::out, mach_info::float_format ff=mach_info::native_float_format(), const std::string &encoding="utf-8")
 
virtual ~base_stream ()=default
 
void close ()
 
virtual void do_close ()
 
std::string error (bool clear, int &err_num)
 
virtual int file_number () const
 
virtual std::istream * input_stream ()
 
bool is_open () const
 
bool ok () const
 
virtual std::ostream * output_stream ()
 
std::ostream * preferred_output_stream ()
 

Protected Member Functions

 ~base_iostream ()=default
 
void invalid_operation () const
 
- Protected Member Functions inherited from base_stream
void clear ()
 
void clearerr ()
 
std::string encoding () const
 
void error (const std::string &msg)
 
void error (const std::string &who, const std::string &msg)
 
mach_info::float_format float_format () const
 
int mode () const
 

Detailed Description

Definition at line 37 of file oct-iostrm.h.

Constructor & Destructor Documentation

◆ base_iostream()

base_iostream::base_iostream ( const std::string &  n = "",
std::ios::openmode  m = std::ios::in | std::ios::out,
mach_info::float_format  ff = mach_info::native_float_format () 
)
inline

Definition at line 42 of file oct-iostrm.h.

◆ ~base_iostream()

base_iostream::~base_iostream ( )
protecteddefault

Member Function Documentation

◆ eof()

bool base_iostream::eof ( ) const
virtual

Implements base_stream.

Reimplemented in ostream, and istream.

Definition at line 59 of file oct-iostrm.cc.

References invalid_operation().

◆ invalid_operation()

void base_iostream::invalid_operation ( ) const
protected

Definition at line 66 of file oct-iostrm.cc.

References base_stream::error().

Referenced by eof(), seek(), and tell().

◆ name()

std::string base_iostream::name ( ) const
inlinevirtual

Implements base_stream.

Definition at line 69 of file oct-iostrm.h.

◆ seek()

int base_iostream::seek ( off_t  offset,
int  origin 
)
virtual

Implements base_stream.

Definition at line 41 of file oct-iostrm.cc.

References invalid_operation().

◆ tell()

off_t base_iostream::tell ( )
virtual

Implements base_stream.

Definition at line 50 of file oct-iostrm.cc.

References invalid_operation().


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