BasicHolder is valid for float, double, bool, and integer types. More...
#include <kaldi-holder-inl.h>
Public Types | |
typedef BasicType | T |
Public Member Functions | |
BasicHolder () | |
void | Clear () |
bool | Read (std::istream &is) |
T & | Value () |
void | Swap (BasicHolder< T > *other) |
bool | ExtractRange (const BasicHolder< T > &other, const std::string &range) |
~BasicHolder () | |
Static Public Member Functions | |
static bool | Write (std::ostream &os, bool binary, const T &t) |
static bool | IsReadInBinary () |
Private Member Functions | |
KALDI_DISALLOW_COPY_AND_ASSIGN (BasicHolder) | |
Private Attributes | |
T | t_ |
BasicHolder is valid for float, double, bool, and integer types.
There will be a compile time error otherwise, because we make sure that the {Write, Read}BasicType functions do not get instantiated for other types.
Definition at line 127 of file kaldi-holder-inl.h.
typedef BasicType T |
Definition at line 129 of file kaldi-holder-inl.h.
|
inline |
Definition at line 131 of file kaldi-holder-inl.h.
|
inline |
Definition at line 211 of file kaldi-holder-inl.h.
References KaldiObjectHolder< KaldiType >::KALDI_DISALLOW_COPY_AND_ASSIGN().
|
inline |
Definition at line 146 of file kaldi-holder-inl.h.
|
inline |
|
inlinestatic |
Definition at line 196 of file kaldi-holder-inl.h.
|
private |
|
inline |
Definition at line 149 of file kaldi-holder-inl.h.
References kaldi::CharToString(), kaldi::InitKaldiInputStream(), KALDI_WARN, kaldi::ReadBasicType(), and KaldiObjectHolder< KaldiType >::t_.
|
inline |
Definition at line 202 of file kaldi-holder-inl.h.
References kaldi::swap(), KaldiObjectHolder< KaldiType >::t_, and BasicHolder< BasicType >::t_.
|
inline |
Definition at line 198 of file kaldi-holder-inl.h.
References KaldiObjectHolder< KaldiType >::t_.
Definition at line 133 of file kaldi-holder-inl.h.
References kaldi::InitKaldiOutputStream(), KALDI_WARN, and kaldi::WriteBasicType().
|
private |
Definition at line 215 of file kaldi-holder-inl.h.
Referenced by BasicHolder< BasicType >::Swap().