Arcane  4.2.3.0
User documentation
Loading...
Searching...
No Matches
Arcane::SerializerExtension Class Reference

Class that extends the functionalities of the ISerializer. More...

#include <arccore/serialize/SerializerExtension.h>

Public Member Functions

 SerializerExtension (ISerializer *serializer)
 Constructor.
template<class Type>
void reserveSpan (Span2< const Type > values) const
 Reserve for a view of values elements.
template<class Type, class Extents>
requires (Extents::rank() <= 4)
void reserveSpan (MDSpan< const Type, Extents > values) const
 Reserve for a view of values elements.
template<class Type>
void reserveArray (Span2< const Type > values) const
 Reserve to save the number of elements and the values elements.
template<class Type, class Extents>
requires (Extents::rank() <= 4)
void reserveArray (MDSpan< const Type, Extents > values) const
 Reserve to save the number of elements and the values elements.
void reserveArray (Span< const String > values) const
 Reserve to save the number of elements and the values elements.
template<class Type>
void putSpan (Span2< const Type > values) const
 Add the array values.
template<class Type, class Extents>
requires (Extents::rank() <= 4)
void putSpan (MDSpan< const Type, Extents > values) const
 Add the array values.
template<class Type>
void putArray (Span2< const Type > values) const
 Save the number of elements and the values elements.
template<class Type, class Extents>
requires (Extents::rank() <= 4)
void putArray (MDSpan< const Type, Extents > values) const
 Save the number of elements and the values elements.
void putArray (Span< const String > values) const
 Save the number of elements and the values elements.
template<class Type>
void getSpan (Span2< Type > values) const
 Retrieve the array values.
template<class Type, class Extents>
requires (Extents::rank() <= 4)
void getSpan (MDSpan< Type, Extents > values) const
 Retrieve the array values.
template<class Type>
void getArray (Array2< Type > &values) const
 Resize and fill values.
template<class Type, class Extents>
requires (Extents::rank() <= 4)
void getArray (NumArray< Type, Extents > &values) const
 Resize and fill values.
void getArray (Array< String > &values) const
 Resize and fill values.

Detailed Description

Class that extends the functionalities of the ISerializer.

This class allows you to serialize multidimensionnal arrays or String arrays. It uses methods of the classical ISerializer. You can destroy this class between steps of serialization, it doesn't store any datas.

Definition at line 37 of file SerializerExtension.h.

Constructor & Destructor Documentation

◆ SerializerExtension()

Arcane::SerializerExtension::SerializerExtension ( ISerializer * serializer)
inline

Constructor.

Parameters
serializerThe classical serializer.

Definition at line 45 of file SerializerExtension.h.

Member Function Documentation

◆ getArray() [1/3]

template<class Type>
void Arcane::SerializerExtension::getArray ( Array2< Type > & values) const

Resize and fill values.

Definition at line 256 of file SerializerExtension.h.

References Arcane::Array2< DataType >::resize(), and Arcane::Array2< DataType >::to1DSpan().

◆ getArray() [2/3]

void Arcane::SerializerExtension::getArray ( Array< String > & values) const

Resize and fill values.

Definition at line 59 of file SerializerExtension.cc.

References Arcane::Array< T >::resize(), and Arcane::Array< T >::span().

◆ getArray() [3/3]

template<class Type, class Extents>
requires (Extents::rank() <= 4)
void Arcane::SerializerExtension::getArray ( NumArray< Type, Extents > & values) const

Resize and fill values.

Definition at line 270 of file SerializerExtension.h.

◆ getSpan() [1/2]

template<class Type, class Extents>
requires (Extents::rank() <= 4)
void Arcane::SerializerExtension::getSpan ( MDSpan< Type, Extents > values) const

Retrieve the array values.

Definition at line 244 of file SerializerExtension.h.

◆ getSpan() [2/2]

template<class Type>
void Arcane::SerializerExtension::getSpan ( Span2< Type > values) const

◆ putArray() [1/3]

template<class Type, class Extents>
requires (Extents::rank() <= 4)
void Arcane::SerializerExtension::putArray ( MDSpan< const Type, Extents > values) const

Save the number of elements and the values elements.

Definition at line 207 of file SerializerExtension.h.

◆ putArray() [2/3]

template<class Type>
void Arcane::SerializerExtension::putArray ( Span2< const Type > values) const

Save the number of elements and the values elements.

Definition at line 195 of file SerializerExtension.h.

References Arcane::Span2Impl< T, SizeType, Extent1, Extent2 >::dim1Size(), Arcane::Span2Impl< T, SizeType, Extent1, Extent2 >::dim2Size(), and putSpan().

◆ putArray() [3/3]

void Arcane::SerializerExtension::putArray ( Span< const String > values) const

Save the number of elements and the values elements.

Definition at line 46 of file SerializerExtension.cc.

References Arcane::SpanImpl< T, SizeType, Extent >::size().

◆ putSpan() [1/2]

template<class Type, class Extents>
requires (Extents::rank() <= 4)
void Arcane::SerializerExtension::putSpan ( MDSpan< const Type, Extents > values) const

Add the array values.

Definition at line 184 of file SerializerExtension.h.

◆ putSpan() [2/2]

template<class Type>
void Arcane::SerializerExtension::putSpan ( Span2< const Type > values) const

◆ reserveArray() [1/3]

template<class Type, class Extents>
requires (Extents::rank() <= 4)
void Arcane::SerializerExtension::reserveArray ( MDSpan< const Type, Extents > values) const

Reserve to save the number of elements and the values elements.

Definition at line 160 of file SerializerExtension.h.

◆ reserveArray() [2/3]

template<class Type>
void Arcane::SerializerExtension::reserveArray ( Span2< const Type > values) const

Reserve to save the number of elements and the values elements.

Definition at line 149 of file SerializerExtension.h.

References reserveSpan().

◆ reserveArray() [3/3]

void Arcane::SerializerExtension::reserveArray ( Span< const String > values) const

Reserve to save the number of elements and the values elements.

Definition at line 33 of file SerializerExtension.cc.

References Arcane::SpanImpl< T, SizeType, Extent >::size().

◆ reserveSpan() [1/2]

template<class Type, class Extents>
requires (Extents::rank() <= 4)
void Arcane::SerializerExtension::reserveSpan ( MDSpan< const Type, Extents > values) const

Reserve for a view of values elements.

Definition at line 138 of file SerializerExtension.h.

◆ reserveSpan() [2/2]

template<class Type>
void Arcane::SerializerExtension::reserveSpan ( Span2< const Type > values) const

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