COMMS
Template library intended to help with implementation of communication protocols.
ArrayList.h
Go to the documentation of this file.
1 //
2 // Copyright 2014 - 2024 (C). Alex Robenko. All rights reserved.
3 //
4 // This Source Code Form is subject to the terms of the Mozilla Public
5 // License, v. 2.0. If a copy of the MPL was not distributed with this
6 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
7 
10 
11 #pragma once
12 
13 #include "comms/CompileControl.h"
14 
15 #include <vector>
16 
17 #if COMMS_HAS_CPP20_SPAN
18 #include <span>
19 #endif // #if COMMS_HAS_CPP20_SPAN
20 
21 #include "comms/ErrorStatus.h"
22 #include "comms/options.h"
24 #include "comms/util/ArrayView.h"
25 #include "comms/util/type_traits.h"
26 #include "basic/ArrayList.h"
27 #include "details/AdaptBasicField.h"
28 #include "details/OptionsParser.h"
29 
30 namespace comms
31 {
32 
33 namespace field
34 {
35 
36 namespace details
37 {
38 
39 template <bool THasOrigDataViewStorage>
40 struct ArrayListOrigDataViewStorageType;
41 
42 template <>
43 struct ArrayListOrigDataViewStorageType<true>
44 {
45 #if COMMS_HAS_CPP20_SPAN
46  template <typename TElement>
47  using Type = std::span<TElement>;
48 #else // #if COMMS_HAS_CPP20_SPAN
49  template <typename TElement>
51 #endif // #if COMMS_HAS_CPP20_SPAN
52 };
53 
54 template <>
55 struct ArrayListOrigDataViewStorageType<false>
56 {
57  template <typename TElement>
58  using Type = std::vector<TElement>;
59 };
60 
61 template <bool THasSequenceFixedSizeUseFixedSizeStorage>
62 struct ArrayListSequenceFixedSizeUseFixedSizeStorageType;
63 
64 template <>
65 struct ArrayListSequenceFixedSizeUseFixedSizeStorageType<true>
66 {
67  template <typename TElement, typename TOpt>
69 };
70 
71 template <>
72 struct ArrayListSequenceFixedSizeUseFixedSizeStorageType<false>
73 {
74  template <typename TElement, typename TOpt>
75  using Type =
76  typename ArrayListOrigDataViewStorageType<
77  TOpt::HasOrigDataView && std::is_integral<TElement>::value && (sizeof(TElement) == sizeof(std::uint8_t))
78  >::template Type<TElement>;
79 };
80 
81 template <bool THasFixedSizeStorage>
82 struct ArrayListFixedSizeStorageType;
83 
84 template <>
85 struct ArrayListFixedSizeStorageType<true>
86 {
87  template <typename TElement, typename TOpt>
89 };
90 
91 template <>
92 struct ArrayListFixedSizeStorageType<false>
93 {
94  template <typename TElement, typename TOpt>
95  using Type =
96  typename ArrayListSequenceFixedSizeUseFixedSizeStorageType<TOpt::HasSequenceFixedSizeUseFixedSizeStorage>
97  ::template Type<TElement, TOpt>;
98 };
99 
100 template <bool THasCustomStorage>
101 struct ArrayListCustomArrayListStorageType;
102 
103 template <>
104 struct ArrayListCustomArrayListStorageType<true>
105 {
106  template <typename TElement, typename TOpt>
107  using Type = typename TOpt::CustomStorageType;
108 };
109 
110 template <>
111 struct ArrayListCustomArrayListStorageType<false>
112 {
113  template <typename TElement, typename TOpt>
114  using Type =
115  typename ArrayListFixedSizeStorageType<TOpt::HasFixedSizeStorage>::template Type<TElement, TOpt>;
116 };
117 
118 template <typename TElement, typename TOpt>
119 using ArrayListStorageTypeT =
120  typename ArrayListCustomArrayListStorageType<TOpt::HasCustomStorageType>::template Type<TElement, TOpt>;
121 
122 template <typename TFieldBase, typename TElement, typename... TOptions>
123 using ArrayListBase =
124  AdaptBasicFieldT<
125  comms::field::basic::ArrayList<
126  TFieldBase,
127  ArrayListStorageTypeT<TElement, OptionsParser<TOptions...> >
128  >,
129  TOptions...
130  >;
131 
132 } // namespace details
133 
190 template <typename TFieldBase, typename TElement, typename... TOptions>
191 class ArrayList : public details::ArrayListBase<TFieldBase, TElement, TOptions...>
192 {
193  using BaseImpl = details::ArrayListBase<TFieldBase, TElement, TOptions...>;
194 public:
196  using FieldBase = TFieldBase;
197 
199  using Endian = typename BaseImpl::Endian;
200 
203 
205  using ParsedOptions = details::OptionsParser<TOptions...>;
206 
208  using CommsTag = typename BaseImpl::CommsTag;
209 
215  using ValueType = typename BaseImpl::ValueType;
216 
218  using ElementType = typename BaseImpl::ElementType;
219 
224 
228 
232 
236 
240 
244 
248 
250  ArrayList() = default;
251 
253  explicit ArrayList(const ValueType& val)
254  : BaseImpl(val)
255  {
256  }
257 
259  explicit ArrayList(ValueType&& val)
260  : BaseImpl(std::move(val))
261  {
262  }
263 
265  ArrayList(const ArrayList&) = default;
266 
268  ArrayList(ArrayList&&) = default;
269 
271  ~ArrayList() noexcept = default;
272 
274  ArrayList& operator=(const ArrayList&) = default;
275 
277  ArrayList& operator=(ArrayList&&) = default;
278 
281  static constexpr bool hasFailOnInvalid()
282  {
283  return ParsedOptions::HasFailOnInvalid;
284  }
285 
288  static constexpr bool hasIgnoreInvalid()
289  {
290  return ParsedOptions::HasIgnoreInvalid;
291  }
292 
295  static constexpr bool hasEmptySerialization()
296  {
297  return ParsedOptions::HasEmptySerialization;
298  }
299 
302  static constexpr bool hasFieldType()
303  {
304  return ParsedOptions::HasFieldType;
305  }
306 
309  static constexpr bool hasSizeFieldPrefix()
310  {
311  return ParsedOptions::HasSequenceSizeFieldPrefix;
312  }
313 
316  static constexpr bool hasSerLengthFieldPrefix()
317  {
318  return ParsedOptions::HasSequenceSerLengthFieldPrefix;
319  }
320 
323  static constexpr bool hasElemSerLengthFieldPrefix()
324  {
325  return ParsedOptions::HasSequenceElemSerLengthFieldPrefix;
326  }
327 
330  static constexpr bool hasElemFixedSerLengthFieldPrefix()
331  {
332  return ParsedOptions::HasSequenceElemFixedSerLengthFieldPrefix;
333  }
334 
337  static constexpr bool hasTerminationFieldSuffix()
338  {
339  return ParsedOptions::HasSequenceTerminationFieldSuffix;
340  }
341 
344  static constexpr bool hasTrailingFieldSuffix()
345  {
346  return ParsedOptions::HasSequenceTrailingFieldSuffix;
347  }
348 
351  static constexpr bool hasFixedSize()
352  {
353  return ParsedOptions::HasSequenceFixedSize;
354  }
355 
359  static constexpr bool fixedSize()
360  {
362  }
363 
366  {
367  return BaseImpl::value();
368  }
369 
371  const ValueType& value() const
372  {
373  return BaseImpl::value();
374  }
375 
378  const ValueType& getValue() const
379  {
380  return BaseImpl::getValue();
381  }
382 
385  template <typename U>
386  void setValue(U&& val)
387  {
388  BaseImpl::setValue(std::forward<U>(val));
389  }
390 
392  constexpr std::size_t length() const
393  {
394  return BaseImpl::length();
395  }
396 
407  template <typename TIter>
408  ErrorStatus read(TIter& iter, std::size_t len)
409  {
410  return BaseImpl::read(iter, len);
411  }
412 
415  static constexpr bool hasReadNoStatus()
416  {
417  return BaseImpl::hasReadNoStatus();
418  }
419 
425  template <typename TIter>
426  void readNoStatus(TIter& iter)
427  {
428  BaseImpl::readNoStatus(iter);
429  }
430 
432  bool canWrite() const
433  {
434  return BaseImpl::canWrite();
435  }
436 
449  template <typename TIter>
450  ErrorStatus write(TIter& iter, std::size_t len) const
451  {
452  return BaseImpl::write(iter, len);
453  }
454 
457  static constexpr bool hasWriteNoStatus()
458  {
459  return BaseImpl::hasWriteNoStatus();
460  }
461 
467  template <typename TIter>
468  void writeNoStatus(TIter& iter) const
469  {
470  BaseImpl::writeNoStatus(iter);
471  }
472 
476  bool valid() const
477  {
478  return BaseImpl::valid();
479  }
480 
484  bool refresh()
485  {
486  return BaseImpl::refresh();
487  }
488 
490  static constexpr std::size_t minLength()
491  {
492  return BaseImpl::minLength();
493  }
494 
496  static constexpr std::size_t maxLength()
497  {
498  return BaseImpl::maxLength();
499  }
500 
506  void forceReadElemCount(std::size_t count)
507  {
508  return BaseImpl::forceReadElemCount(count);
509  }
510 
516  {
517  return BaseImpl::clearReadElemCount();
518  }
519 
524  void forceReadLength(std::size_t count)
525  {
526  return BaseImpl::forceReadLength(count);
527  }
528 
534  {
535  return BaseImpl::clearReadLengthForcing();
536  }
537 
544  void forceReadElemLength(std::size_t count)
545  {
546  return BaseImpl::forceReadElemLength(count);
547  }
548 
553  {
554  return BaseImpl::clearReadElemLengthForcing();
555  }
556 
558  static constexpr bool isVersionDependent()
559  {
560  return ParsedOptions::HasCustomVersionUpdate || BaseImpl::isVersionDependent();
561  }
562 
564  static constexpr bool hasNonDefaultRefresh()
565  {
566  return BaseImpl::hasNonDefaultRefresh();
567  }
568 
572  {
573  return BaseImpl::getVersion();
574  }
575 
579  {
580  return BaseImpl::setVersion(version);
581  }
582 
583 #ifdef FOR_DOXYGEN_DOC_ONLY
589  auto terminationFieldSuffix() -> decltype(BaseImpl::terminationFieldSuffix())
590  {
591  return BaseImpl::terminationFieldSuffix();
592  }
593 
599  auto terminationFieldSuffix() const -> decltype(BaseImpl::terminationFieldSuffix())
600  {
601  return BaseImpl::terminationFieldSuffix();
602  }
603 
604 #endif // #ifdef FOR_DOXYGEN_DOC_ONLY
605 
606 protected:
607  using BaseImpl::readData;
608  using BaseImpl::writeData;
609 
610 private:
611  static_assert(!ParsedOptions::HasSerOffset,
612  "comms::option::def::NumValueSerOffset option is not applicable to ArrayList field");
613  static_assert(!ParsedOptions::HasFixedLengthLimit,
614  "comms::option::def::FixedLength option is not applicable to ArrayList field");
615  static_assert(!ParsedOptions::HasFixedBitLengthLimit,
616  "comms::option::def::FixedBitLength option is not applicable to ArrayList field");
617  static_assert(!ParsedOptions::HasVarLengthLimits,
618  "comms::option::def::VarLength option is not applicable to ArrayList field");
619  static_assert(!ParsedOptions::HasAvailableLengthLimit,
620  "comms::option::def::AvailableLengthLimit option is not applicable to ArrayList field");
621  static_assert(!ParsedOptions::HasScalingRatio,
622  "comms::option::def::ScalingRatio option is not applicable to ArrayList field");
623  static_assert(!ParsedOptions::HasUnits,
624  "comms::option::def::Units option is not applicable to ArrayList field");
625  static_assert(!ParsedOptions::HasMultiRangeValidation,
626  "comms::option::def::ValidNumValueRange (or similar) option is not applicable to ArrayList field");
627  static_assert((!ParsedOptions::HasOrigDataView) || (std::is_integral<TElement>::value && (sizeof(TElement) == sizeof(std::uint8_t))),
628  "Usage of comms::option::app::OrigDataView option is allowed only for raw binary data (std::uint8_t) types.");
629  static_assert(!ParsedOptions::HasVersionsRange,
630  "comms::option::def::ExistsBetweenVersions (or similar) option is not applicable to ArrayList field");
631  static_assert(!ParsedOptions::HasInvalidByDefault,
632  "comms::option::def::InvalidByDefault option is not applicable to ArrayList field");
633  static_assert(!ParsedOptions::HasMissingOnReadFail,
634  "comms::option::def::MissingOnReadFail option is not applicable to ArrayList field");
635  static_assert(!ParsedOptions::HasMissingOnInvalid,
636  "comms::option::def::MissingOnInvalid option is not applicable to ArrayList field");
637 };
638 
645 template <typename TFieldBase, typename TElement, typename... TOptions>
648  const ArrayList<TFieldBase, TElement, TOptions...>& field2) noexcept
649 {
650  return std::lexicographical_compare(
651  field1.value().begin(), field1.value().end(),
652  field2.value().begin(), field2.value().end());
653 }
654 
660 template <typename TFieldBase, typename TElement, typename... TOptions>
663  const ArrayList<TFieldBase, TElement, TOptions...>& field2) noexcept
664 {
665  auto& vec1 = field1.value();
666  auto& vec2 = field2.value();
667  if (vec1.size() != vec2.size()) {
668  return false;
669  }
670 
671  for (auto idx = 0U; idx < vec1.size(); ++idx) {
672  if (vec1[idx] != vec2[idx]) {
673  return false;
674  }
675  }
676  return true;
677 }
678 
684 template <typename TFieldBase, typename TElement, typename... TOptions>
687  const ArrayList<TFieldBase, TElement, TOptions...>& field2) noexcept
688 {
689  return !(field1 == field2);
690 }
691 
697 template <typename T>
698 constexpr bool isArrayList()
699 {
700  return
701  std::is_same<typename T::CommsTag, tag::ArrayList>::value ||
702  std::is_same<typename T::CommsTag, tag::RawArrayList>::value;
703 }
704 
708 template <typename TFieldBase, typename TElement, typename... TOptions>
709 inline
710 ArrayList<TFieldBase, TElement, TOptions...>&
712 {
713  return field;
714 }
715 
719 template <typename TFieldBase, typename TElement, typename... TOptions>
720 inline
721 const ArrayList<TFieldBase, TElement, TOptions...>&
723 {
724  return field;
725 }
726 
727 
728 } // namespace field
729 
730 } // namespace comms
731 
Contains comms::util::ArrayView class.
Contains various compiler related definitions.
This file contain definition of error statuses used by comms module.
Contains comms::util::StaticVector class.
Field that represents a sequential collection of fields.
Definition: ArrayList.h:192
static constexpr bool hasEmptySerialization()
Compile time inquiry of whether comms::option::def::EmptySerialization option has been used.
Definition: ArrayList.h:295
static constexpr bool hasFixedSize()
Compile time inquiry of whether comms::option::def::SequenceFixedSize option has been used.
Definition: ArrayList.h:351
typename BaseImpl::ElementType ElementType
Type of the element.
Definition: ArrayList.h:218
typename BaseImpl::VersionType VersionType
Version type.
Definition: ArrayList.h:202
static constexpr bool hasTrailingFieldSuffix()
Compile time inquiry of whether comms::option::def::SequenceTrailingFieldSuffix option has been used.
Definition: ArrayList.h:344
void clearReadElemLengthForcing()
Clear forcing the serialisation length of the single element.
Definition: ArrayList.h:552
static constexpr bool hasElemSerLengthFieldPrefix()
Compile time inquiry of whether comms::option::def::SequenceElemSerLengthFieldPrefix option has been ...
Definition: ArrayList.h:323
void writeNoStatus(TIter &iter) const
Write current field value to output data sequence without error check and status report.
Definition: ArrayList.h:468
typename ParsedOptions::SequenceTrailingFieldSuffix TrailingFieldSuffix
Type of trailing field suffix specified via comms::option::def::SequenceTrailingFieldSuffix.
Definition: ArrayList.h:247
static constexpr bool hasFailOnInvalid()
Compile time inquiry of whether comms::option::def::FailOnInvalid option has been used.
Definition: ArrayList.h:281
ErrorStatus read(TIter &iter, std::size_t len)
Read field value from input data sequence.
Definition: ArrayList.h:408
static constexpr bool hasReadNoStatus()
Compile time check of whether the field has proper readNoStatus() member function.
Definition: ArrayList.h:415
static constexpr bool isVersionDependent()
Compile time check if this class is version dependent.
Definition: ArrayList.h:558
VersionType getVersion() const
Get version of the field.
Definition: ArrayList.h:571
const ArrayList< TFieldBase, TElement, TOptions... > & toFieldBase(const ArrayList< TFieldBase, TElement, TOptions... > &field)
Upcast type of the field definition to its parent comms::field::ArrayList type in order to have acces...
Definition: ArrayList.h:722
typename BaseImpl::Endian Endian
Endian used for serialisation.
Definition: ArrayList.h:199
void clearReadLengthForcing()
Clear forcing of the available length in the next read() invocation.
Definition: ArrayList.h:533
static constexpr bool hasTerminationFieldSuffix()
Compile time inquiry of whether comms::option::def::SequenceTerminationFieldSuffix option has been us...
Definition: ArrayList.h:337
void setValue(U &&val)
Set value.
Definition: ArrayList.h:386
ValueType & value()
Get access to the value storage.
Definition: ArrayList.h:365
bool operator<(const ArrayList< TFieldBase, TElement, TOptions... > &field1, const ArrayList< TFieldBase, TElement, TOptions... > &field2) noexcept
Equivalence comparison operator.
Definition: ArrayList.h:646
const ValueType & getValue() const
Get value.
Definition: ArrayList.h:378
ArrayList(const ValueType &val)
Value constructor.
Definition: ArrayList.h:253
void readNoStatus(TIter &iter)
Read field value from input data sequence without error check and status report.
Definition: ArrayList.h:426
typename ParsedOptions::SequenceSizeFieldPrefix SizeFieldPrefix
Type of size field prefix specified via comms::option::def::SequenceSizeFieldPrefix.
Definition: ArrayList.h:227
void forceReadElemCount(std::size_t count)
Force number of elements that must be read in the next read() invocation.
Definition: ArrayList.h:506
typename ParsedOptions::SequenceElemSerLengthFieldPrefix ElemSerLengthFieldPrefix
Type of element's length field prefix specified via comms::option::def::SequenceElemSerLengthFieldPre...
Definition: ArrayList.h:235
ArrayList(const ArrayList &)=default
Copy constructor.
constexpr std::size_t length() const
Get length of serialised data.
Definition: ArrayList.h:392
void forceReadElemLength(std::size_t count)
Force serialisation length of a single element.
Definition: ArrayList.h:544
static constexpr std::size_t minLength()
Get minimal length that is required to serialise field of this type.
Definition: ArrayList.h:490
ArrayList< TFieldBase, TElement, TOptions... > & toFieldBase(ArrayList< TFieldBase, TElement, TOptions... > &field)
Upcast type of the field definition to its parent comms::field::ArrayList type in order to have acces...
Definition: ArrayList.h:711
~ArrayList() noexcept=default
Destructor.
bool refresh()
Refresh the field.
Definition: ArrayList.h:484
typename BaseImpl::ValueType ValueType
Type of underlying value.
Definition: ArrayList.h:215
constexpr bool isArrayList()
Compile time check function of whether a provided type is any variant of comms::field::ArrayList.
Definition: ArrayList.h:698
bool setVersion(VersionType version)
Default implementation of version update.
Definition: ArrayList.h:578
static constexpr bool hasSerLengthFieldPrefix()
Compile time inquiry of whether comms::option::def::SequenceSerLengthFieldPrefix option has been used...
Definition: ArrayList.h:316
auto terminationFieldSuffix() const -> decltype(BaseImpl::terminationFieldSuffix())
Access list termination field (const variant)
Definition: ArrayList.h:599
typename ParsedOptions::FieldType FieldType
Type of actual extending field specified via comms::option::def::FieldType.
Definition: ArrayList.h:223
static constexpr bool hasElemFixedSerLengthFieldPrefix()
Compile time inquiry of whether comms::option::def::SequenceElemFixedSerLengthFieldPrefix option has ...
Definition: ArrayList.h:330
static constexpr bool hasWriteNoStatus()
Compile time check of whether the field has proper writeNoStatus() member function.
Definition: ArrayList.h:457
bool valid() const
Check validity of the field value.
Definition: ArrayList.h:476
static constexpr bool hasIgnoreInvalid()
Compile time inquiry of whether comms::option::def::IgnoreInvalid option has been used.
Definition: ArrayList.h:288
typename ParsedOptions::SequenceSerLengthFieldPrefix SerLengthFieldPrefix
Type of length field prefix specified via comms::option::def::SequenceSerLengthFieldPrefix.
Definition: ArrayList.h:231
static constexpr bool fixedSize()
Compile time inquiry of fixed size provided via comms::option::def::SequenceFixedSize option.
Definition: ArrayList.h:359
typename ParsedOptions::SequenceElemFixedSerLengthFieldPrefix ElemFixedSerLengthFieldPrefix
Type of element's fixed length field prefix specified via comms::option::def::SequenceElemFixedSerLen...
Definition: ArrayList.h:239
TFieldBase FieldBase
Base class provided in the first template parameter.
Definition: ArrayList.h:196
ErrorStatus write(TIter &iter, std::size_t len) const
Write current field value to output data sequence.
Definition: ArrayList.h:450
auto terminationFieldSuffix() -> decltype(BaseImpl::terminationFieldSuffix())
Access list termination field.
Definition: ArrayList.h:589
static constexpr bool hasFieldType()
Compile time inquiry of whether comms::option::def::FieldType option has been used.
Definition: ArrayList.h:302
ArrayList(ArrayList &&)=default
Move constructor.
bool canWrite() const
Check of whether the field has a consistent value for writing.
Definition: ArrayList.h:432
void clearReadElemCount()
Clear forcing of the number of elements that must be read in the next read() invocation.
Definition: ArrayList.h:515
void forceReadLength(std::size_t count)
Force available length for the next read() invocation.
Definition: ArrayList.h:524
static constexpr bool hasNonDefaultRefresh()
Compile time check if this class has non-default refresh functionality.
Definition: ArrayList.h:564
const ValueType & value() const
Get access to the value storage.
Definition: ArrayList.h:371
static constexpr std::size_t maxLength()
Get maximal length that is required to serialise field of this type.
Definition: ArrayList.h:496
bool operator!=(const ArrayList< TFieldBase, TElement, TOptions... > &field1, const ArrayList< TFieldBase, TElement, TOptions... > &field2) noexcept
Non-equality comparison operator.
Definition: ArrayList.h:685
details::OptionsParser< TOptions... > ParsedOptions
All the options provided to this class bundled into struct.
Definition: ArrayList.h:205
typename BaseImpl::CommsTag CommsTag
Tag indicating type of the field.
Definition: ArrayList.h:208
typename ParsedOptions::SequenceTerminationFieldSuffix TerminationFieldSuffix
Type of termination field suffix specified via comms::option::def::SequenceTerminationFieldSuffix.
Definition: ArrayList.h:243
ArrayList()=default
Default constructor.
bool operator==(const ArrayList< TFieldBase, TElement, TOptions... > &field1, const ArrayList< TFieldBase, TElement, TOptions... > &field2) noexcept
Equality comparison operator.
Definition: ArrayList.h:661
ArrayList(ValueType &&val)
Value constructor.
Definition: ArrayList.h:259
static constexpr bool hasSizeFieldPrefix()
Compile time inquiry of whether comms::option::def::SequenceSizeFieldPrefix option has been used.
Definition: ArrayList.h:309
Describes an object that can refer to a constant contiguous sequence of other objects.
Definition: ArrayView.h:31
Replacement to std::vector when no dynamic memory allocation is allowed.
Definition: StaticVector.h:965
comms::option::def::SequenceTrailingFieldSuffix< TField > SequenceTrailingFieldSuffix
Same as comms::option::def::SequenceTrailingFieldSuffix.
Definition: options.h:1531
comms::option::def::SequenceElemFixedSerLengthFieldPrefix< TField, TReadErrorStatus > SequenceElemFixedSerLengthFieldPrefix
Same as comms::option::def::SequenceElemFixedSerLengthFieldPrefix.
Definition: options.h:1523
comms::option::def::SequenceTerminationFieldSuffix< TField > SequenceTerminationFieldSuffix
Same as comms::option::def::SequenceTerminationFieldSuffix.
Definition: options.h:1527
comms::option::def::SequenceSerLengthFieldPrefix< TField, TReadErrorStatus > SequenceSerLengthFieldPrefix
Same as comms::option::def::SequenceSerLengthFieldPrefix.
Definition: options.h:1513
comms::option::def::SequenceFixedSize< TSize > SequenceFixedSize
Same as comms::option::def::SequenceFixedSize.
Definition: options.h:1544
comms::option::def::HasCustomVersionUpdate HasCustomVersionUpdate
Same as comms::option::def::HasCustomVersionUpdate.
Definition: options.h:1800
comms::option::def::VersionType< T > VersionType
Same as comms::option::def::VersionType.
Definition: options.h:1797
comms::option::def::FieldType< TMsg > FieldType
Same as comms::option::def::FieldType.
Definition: options.h:1463
comms::option::def::SequenceElemSerLengthFieldPrefix< TField, TReadErrorStatus > SequenceElemSerLengthFieldPrefix
Same as comms::option::def::SequenceElemSerLengthFieldPrefix.
Definition: options.h:1518
comms::option::app::CustomStorageType< TType > CustomStorageType
Same as comms::option::app::CustomStorageType.
Definition: options.h:1891
comms::option::def::Endian< TEndian > Endian
Same as comms::option::def::Endian.
Definition: options.h:1438
comms::option::def::SequenceSizeFieldPrefix< TField > SequenceSizeFieldPrefix
Same as comms::option::def::SequenceSizeFieldPrefix.
Definition: options.h:1508
T readData(TIter &iter, const traits::endian::Big &endian)
Same as readBig<T, TIter>()
Definition: access.h:766
void writeData(T value, TIter &iter, const traits::endian::Big &endian)
Same as writeBig<T, TIter>()
Definition: access.h:698
Main namespace for all classes / functions of COMMS library.
ErrorStatus
Error statuses reported by the Communication module.
Definition: ErrorStatus.h:17
constexpr unsigned version()
Version of the COMMS library as single numeric value.
Definition: version.h:64
Contains definition of all the options used by the COMMS library.
Replacement to some types from standard type_traits.