Home | History | Annotate | Download | only in script

Lines Matching refs:weight

17 // Represents a generic weight in an FST -- that is, represents a specific
18 // type of weight underneath while hiding that type from a client.
44 W weight;
46 explicit WeightClassImpl(const W& weight) : weight(weight) { }
49 return new WeightClassImpl<W>(weight);
55 *o << weight;
60 WeightToStr(weight, &str);
71 return typed_other->weight == weight;
82 explicit WeightClass(const W& weight)
83 : element_type_(OTHER), impl_(new WeightClassImpl<W>(weight)) { }
152 // We need to store zero and one as statics, because the weight type
168 return &typed_impl->weight;
174 // Registration for generic weight types.
205 #define REGISTER_FST_WEIGHT__(Weight, line) \
207 Weight::Type(), \
208 StrToWeightImplBase<Weight>)
211 #define REGISTER_FST_WEIGHT_EXPANDER(Weight, line) \
212 REGISTER_FST_WEIGHT__(Weight, line)
215 // Macro for registering new weight types. Clients call this.
217 #define REGISTER_FST_WEIGHT(Weight) \
218 REGISTER_FST_WEIGHT_EXPANDER(Weight, __LINE__)