Loading...
Searching...
No Matches
DataCommInterface.tpp
1/*---------------------------------------------------------------------------*\
2 *
3 * bitpit
4 *
5 * Copyright (C) 2015-2021 OPTIMAD engineering Srl
6 *
7 * -------------------------------------------------------------------------
8 * License
9 * This file is part of bitpit.
10 *
11 * bitpit is free software: you can redistribute it and/or modify it
12 * under the terms of the GNU Lesser General Public License v3 (LGPL)
13 * as published by the Free Software Foundation.
14 *
15 * bitpit is distributed in the hope that it will be useful, but WITHOUT
16 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
17 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
18 * License for more details.
19 *
20 * You should have received a copy of the GNU Lesser General Public License
21 * along with bitpit. If not, see <http://www.gnu.org/licenses/>.
22 *
23\*---------------------------------------------------------------------------*/
24
25namespace bitpit {
26
27template <class Impl>
28DataCommInterface<Impl>::DataCommInterface(){}
29
34template <class Impl>
35size_t DataCommInterface<Impl>::size(const uint32_t e) const {
36 return getImpl().size(e);
37};
38
42template <class Impl>
44 return getImpl().fixedSize();
45};
46
64template<class Impl>
65template<class Buffer>
66void DataCommInterface<Impl>::gather(Buffer& buff, const uint32_t e) {
67 return getImpl().gather(buff,e);
68}
69
87template<class Impl>
88template<class Buffer>
89void DataCommInterface<Impl>::scatter(Buffer& buff, const uint32_t e) {
90 return getImpl().scatter(buff,e);
91}
92
93
94template <class Impl>
96 return static_cast<Impl &>(*this);
97}
98
99template <class Impl>
100const Impl& DataCommInterface<Impl>::getImpl() const{
101 return static_cast<const Impl &>(*this);
102}
103
104}
Base class for data communications.
void scatter(Buffer &buff, const uint32_t e)
void gather(Buffer &buff, const uint32_t e)
size_t size(const uint32_t e) const
--- layout: doxygen_footer ---