Alien  1.3.0
User documentation
Loading...
Searching...
No Matches
Alien::IMatrixConverter Class Referenceabstract

Matrices converter. More...

#include <core/alien/core/backend/IMatrixConverter.h>

Public Types

typedef Alien::IMatrixImpl IMatrixImpl
 Type of matrix implementation.
typedef Alien::BackEndId BackEndId
 Type of matrix backend.

Public Member Functions

virtual ~IMatrixConverter ()
 Free resources.
virtual BackEndId sourceBackend () const =0
 Get the source backend id.
virtual BackEndId targetBackend () const =0
 Get the target backend id.
virtual void convert (const IMatrixImpl *sourceImpl, IMatrixImpl *targetImpl) const =0
 Convert a matrix from one format to another.
Public Member Functions inherited from Alien::ObjectWithTrace
template<typename T>
void alien_info (T &&t) const
template<typename T>
void alien_debug (T &&t) const
template<typename T>
void alien_warning (T &&t) const
template<typename T>
void alien_fatal (T &&t) const
ITraceMng * traceMng () const

Static Public Member Functions

template<typename T>
static T & cast (IMatrixImpl *impl, BackEndId backend)
 Cast a matrix implementation in its actual type.
template<typename T>
static const T & cast (const IMatrixImpl *impl, BackEndId backend)
 Const cast a matrix implementation in its actual type.

Additional Inherited Members

Protected Member Functions inherited from Alien::ObjectWithTrace
TraceMessage cout () const

Detailed Description

Matrices converter.

Interface to convert a matrix in another format, provided a converter between those two formats has been registered. If there is no direct converter between the source and target format, a third intermediate format will be used if available.

Definition at line 34 of file IMatrixConverter.h.

Member Typedef Documentation

◆ BackEndId

typedef Alien::BackEndId Alien::IMatrixConverter::BackEndId

Type of matrix backend.

Definition at line 40 of file IMatrixConverter.h.

◆ IMatrixImpl

Type of matrix implementation.

Definition at line 38 of file IMatrixConverter.h.

Constructor & Destructor Documentation

◆ ~IMatrixConverter()

virtual Alien::IMatrixConverter::~IMatrixConverter ( )
inlinevirtual

Free resources.

Definition at line 44 of file IMatrixConverter.h.

Member Function Documentation

◆ cast() [1/2]

template<typename T>
const T & Alien::IMatrixConverter::cast ( const IMatrixImpl * impl,
BackEndId backend )
inlinestatic

Const cast a matrix implementation in its actual type.

Parameters
[in]Internal data structure access.Matrix implemenantation
[in]backendBackend id
Returns
The actual matrix implementation

Definition at line 94 of file IMatrixConverter.h.

References Alien::IMatrixImpl::backend().

◆ cast() [2/2]

template<typename T>
T & Alien::IMatrixConverter::cast ( IMatrixImpl * impl,
BackEndId backend )
inlinestatic

◆ convert()

virtual void Alien::IMatrixConverter::convert ( const IMatrixImpl * sourceImpl,
IMatrixImpl * targetImpl ) const
pure virtual

Convert a matrix from one format to another.

Parameters
[in]sourceImplImplementation of the source matrix
[in,out]targetImplImplementation of the target matrix

Implemented in Alien::DoKtoSimpleCSRMatrixConverter, Alien::RedistributorToSimpleCSRMatrixConverter, Alien::SimpleCSRtoDoKMatrixConverter, Alien::SimpleCSRtoRedistributorMatrixConverter, HCSRtoSYCLMatrixConverter, and SimpleCSRtoSYCLMatrixConverter.

◆ sourceBackend()

◆ targetBackend()


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