diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2011-01-25 22:30:48 +0200 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2011-01-25 22:30:48 +0200 |
commit | 931a036dc3cf9e1deafc10e78e94a0ebe3c8004f (patch) | |
tree | 9e1935fc4deafdbd04a8d38835c91b57f359cdee /klm/util/key_value_packing.hh | |
parent | bee6a3c3f6c54cf7449229488c6124dddc7e2f31 (diff) |
update kenlm
Diffstat (limited to 'klm/util/key_value_packing.hh')
-rw-r--r-- | klm/util/key_value_packing.hh | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/klm/util/key_value_packing.hh b/klm/util/key_value_packing.hh index 450512ac..b84a5aad 100644 --- a/klm/util/key_value_packing.hh +++ b/klm/util/key_value_packing.hh @@ -18,6 +18,8 @@ template <class Key, class Value> struct Entry { const Key &GetKey() const { return key; } const Value &GetValue() const { return value; } + Value &MutableValue() { return value; } + void Set(const Key &key_in, const Value &value_in) { SetKey(key_in); SetValue(value_in); @@ -77,6 +79,8 @@ template <class KeyT, class ValueT> class ByteAlignedPacking { const Key &GetKey() const { return key; } const Value &GetValue() const { return value; } + Value &MutableValue() { return value; } + void Set(const Key &key_in, const Value &value_in) { SetKey(key_in); SetValue(value_in); |