FST  openfst-1.6.1
OpenFst Library
info.h
Go to the documentation of this file.
1 // See www.openfst.org for extensive documentation on this weighted
2 // finite-state transducer library.
3 
4 #ifndef FST_SCRIPT_INFO_H_
5 #define FST_SCRIPT_INFO_H_
6 
7 #include <fst/script/arg-packs.h>
8 #include <fst/script/fst-class.h>
9 #include <fst/script/info-impl.h>
10 
11 namespace fst {
12 namespace script {
13 
14 using InfoArgs = args::Package<const FstClass &, bool, const string &,
15  const string &, bool, bool>;
16 
17 template <class Arc>
18 void PrintFstInfo(InfoArgs *args) {
19  const Fst<Arc> &fst = *(args->arg1.GetFst<Arc>());
20  FstInfo<Arc> fstinfo(fst, args->arg2, args->arg3, args->arg4, args->arg5);
21  PrintFstInfo(fstinfo, args->arg6);
22  if (args->arg6) fst.Write("");
23 }
24 
25 void PrintFstInfo(const FstClass &f, bool test_properties,
26  const string &arc_filter, const string &info_type, bool pipe,
27  bool verify);
28 
29 } // namespace script
30 } // namespace fst
31 
32 #endif // FST_SCRIPT_INFO_H_
virtual bool Write(std::ostream &strm, const FstWriteOptions &opts) const
Definition: fst.h:270
void PrintFstInfo(InfoArgs *args)
Definition: info.h:18
args::Package< const FstClass &, bool, const string &, const string &, bool, bool > InfoArgs
Definition: info.h:15