11/*
2- * Copyright 2015 - 2016 Real Logic Ltd.
2+ * Copyright 2015 - 2017 Real Logic Ltd.
33 *
44 * Licensed under the Apache License, Version 2.0 (the "License");
55 * you may not use this file except in compliance with the License.
@@ -291,10 +291,19 @@ class Encoding
291291 std::string characterEncoding,
292292 std::string epoch,
293293 std::string timeUnit,
294- std::string semanticType) :
295- m_presence (presence), m_primitiveType(type), m_byteOrder(byteOrder), m_minValue(minValue), m_maxValue(maxValue),
296- m_nullValue (nullValue), m_constValue(constValue), m_characterEncoding(characterEncoding), m_epoch(epoch),
297- m_timeUnit (timeUnit), m_semanticType(semanticType)
294+ std::string semanticType)
295+ :
296+ m_presence (presence),
297+ m_primitiveType (type),
298+ m_byteOrder (byteOrder),
299+ m_minValue (minValue),
300+ m_maxValue (maxValue),
301+ m_nullValue (nullValue),
302+ m_constValue (constValue),
303+ m_characterEncoding (characterEncoding),
304+ m_epoch (epoch),
305+ m_timeUnit (timeUnit),
306+ m_semanticType (semanticType)
298307 {
299308 }
300309
@@ -405,17 +414,17 @@ class Encoding
405414 }
406415 }
407416
408- inline Presence presence () const
417+ inline const Presence presence () const
409418 {
410419 return m_presence;
411420 }
412421
413- inline ByteOrder byteOrder () const
422+ inline const ByteOrder byteOrder () const
414423 {
415424 return m_byteOrder;
416425 }
417426
418- inline PrimitiveType primitiveType () const
427+ inline const PrimitiveType primitiveType () const
419428 {
420429 return m_primitiveType;
421430 }
@@ -435,25 +444,60 @@ class Encoding
435444 return getDouble (m_primitiveType, m_byteOrder, buffer);
436445 }
437446
447+ inline const PrimitiveValue& minValue () const
448+ {
449+ return m_minValue;
450+ }
451+
452+ inline const PrimitiveValue& maxValue () const
453+ {
454+ return m_maxValue;
455+ }
456+
457+ inline const PrimitiveValue& nullValue () const
458+ {
459+ return m_nullValue;
460+ }
461+
438462 inline const PrimitiveValue& constValue () const
439463 {
440464 return m_constValue;
441465 }
442466
467+ inline const std::string& characterEncoding () const
468+ {
469+ return m_characterEncoding;
470+ }
471+
472+ inline const std::string& epoch () const
473+ {
474+ return m_epoch;
475+ }
476+
477+ inline const std::string& timeUnit () const
478+ {
479+ return m_timeUnit;
480+ }
481+
482+ inline const std::string& semanticType () const
483+ {
484+ return m_semanticType;
485+ }
486+
443487private:
444- Presence m_presence;
445- PrimitiveType m_primitiveType;
446- ByteOrder m_byteOrder;
447-
448- PrimitiveValue m_minValue;
449- PrimitiveValue m_maxValue;
450- PrimitiveValue m_nullValue;
451- PrimitiveValue m_constValue;
452-
453- std::string m_characterEncoding;
454- std::string m_epoch;
455- std::string m_timeUnit;
456- std::string m_semanticType;
488+ const Presence m_presence;
489+ const PrimitiveType m_primitiveType;
490+ const ByteOrder m_byteOrder;
491+
492+ const PrimitiveValue m_minValue;
493+ const PrimitiveValue m_maxValue;
494+ const PrimitiveValue m_nullValue;
495+ const PrimitiveValue m_constValue;
496+
497+ const std::string m_characterEncoding;
498+ const std::string m_epoch;
499+ const std::string m_timeUnit;
500+ const std::string m_semanticType;
457501};
458502
459503}}
0 commit comments