libime
Public Member Functions | List of all members
libime::TableLatticeNode Class Reference
Inheritance diagram for libime::TableLatticeNode:
Inheritance graph
[legend]
Collaboration diagram for libime::TableLatticeNode:
Collaboration graph
[legend]

Public Member Functions

 TableLatticeNode (std::string_view word, WordIndex idx, SegmentGraphPath path, const State &state, float cost, std::unique_ptr< TableLatticeNodePrivate > data)
 
uint32_t index () const
 
PhraseFlag flag () const
 
const std::string & code () const
 
size_t codeLength () const
 
- Public Member Functions inherited from libime::LatticeNode
 LatticeNode (std::string_view word, WordIndex idx, SegmentGraphPath path, const State &state, float cost=0)
 
float cost () const
 
float score () const
 
void setScore (float score)
 
const SegmentGraphNodefrom () const
 
const SegmentGraphNodeto () const
 
const SegmentGraphPath & path () const
 
LatticeNodeprev () const
 
void setPrev (LatticeNode *prev)
 
template<typename T >
 requires (std::is_base_of_v< LatticeNode, T >) T &as()
 
template<typename T >
 requires (std::is_base_of_v< LatticeNode, T >) const T &as() const
 
std::string fullWord () const
 Return the full word till the begining of the sentence.
 
SentenceResult toSentenceResult (float adjust=0.0F) const
 
State & state ()
 
- Public Member Functions inherited from libime::WordNode
 WordNode (std::string_view word, WordIndex idx)
 
 WordNode (WordNode &&other) noexcept(std::is_nothrow_move_constructible_v< std::string >)
 
WordNodeoperator= (WordNode &&other) noexcept(std::is_nothrow_move_assignable_v< std::string >)
 
const std::string & word () const
 
WordIndex idx () const
 
void setIdx (WordIndex idx)
 

Additional Inherited Members

- Protected Attributes inherited from libime::LatticeNode
SegmentGraphPath path_
 
float cost_
 
float score_ = 0.0F
 
State state_
 
LatticeNodeprev_ = nullptr
 
- Protected Attributes inherited from libime::WordNode
std::string word_
 
WordIndex idx_
 

Detailed Description

Definition at line 25 of file tabledecoder.h.


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