HFST - Helsinki Finite-State Transducer Technology - C++ API  version 3.9.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
List of all members
StreamIsClosedException Struct Reference

Stream is closed. More...

#include <HfstExceptionDefs.h>

Inheritance diagram for StreamIsClosedException:
HfstException

Additional Inherited Members

- Public Member Functions inherited from HfstException
HFSTDLL std::string operator() (void) const
 Get the error message. More...
 

Detailed Description

Stream is closed.

Thrown by hfst::HfstTransducer::write_in_att_format hfst::HfstTransducer(FILE*, ImplementationType, const std::string&) hfst::HfstTransducer(const hfst::HfstInputStream&) hfst::HfstOutputStream::operator<<

An example:

try {
  HfstTransducer tr("foo", LOG_OPENFST_TYPE);
  HfstOutputStream out("testfile");
  out.close();
  out << tr;
} catch (StreamIsClosedException e) {
  fprintf(stderr, "ERROR: stream to file is closed.\n");
}  

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