12#ifndef ARCANE_CORE_ITEMINDEXARRAYVIEW_H
13#define ARCANE_CORE_ITEMINDEXARRAYVIEW_H
17#include "arcane/utils/ArrayView.h"
44 friend ItemVectorView;
46 template <
int Extent>
friend class ItemConnectedListView;
47 template <
typename ItemType,
int Extent>
friend class ItemConnectedListViewT;
48 template <
typename ItemType>
friend class ItemVectorViewT;
68 : m_view(local_ids, 0)
81 return m_view.localId(index);
98 return ItemIndexArrayView(m_view._idsWithoutOffset().subView(abegin, asize), m_view.m_local_id_offset, m_flags);
106 bool isContigous()
const {
return isContiguous(); }
111 return m_flags & F_Contigous;
126 return m_view._idsWithoutOffset();
129 ARCANE_DEPRECATED_REASON(
"Y2023: This method is internal to Arcane. Do not use it")
137 ARCANE_DEPRECATED_REASON(
"Y2023: This method is internal to Arcane. Do not use it")
138 const Int32* unguardedBasePointer()
const
143 ARCANE_DEPRECATED_REASON(
"Y2023: This method is internal to Arcane. Do not use it")
144 const Int32* data()
const
151 impl::ItemLocalIdListContainerView m_view;
156 ItemIndexArrayView(SmallSpan<const Int32> local_ids, Int32 local_id_offset, Int32 aflags)
157 : m_view(local_ids, local_id_offset)
161 const Int32* _data()
const
163 return m_view.m_local_ids;
168 return m_view._idsWithoutOffset();
170 Int32 _localIdOffset()
const
172 return m_view.m_local_id_offset;
Declarations of types used in Arcane.
Base class for 1D data vectors.
View over an index array (localIds()) of entities.
bool isContiguous() const
True if the localIds() are contiguous.
ItemIndexArrayView(const Int32ConstArrayView local_ids)
Constructs a view from the local IDs local_ids.
ItemIndexArrayView subView(Integer abegin, Integer asize) const
Sub-view starting from element abegin and containing asize elements.
Int32 size() const
Number of elements in the vector.
ItemIndexArrayView()=default
Constructs an empty view.
Int32ConstArrayView localIds() const
Array of local IDs of entities.
Int32 operator[](Integer index) const
Accesses the i-th element of the vector.
@ F_Contiguous
The local IDs are contiguous.
View over the container of a list of ItemLocalId.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
Int32 Integer
Type representing an integer.
ConstArrayView< Int32 > Int32ConstArrayView
C equivalent of a 1D array of 32-bit integers.
std::int32_t Int32
Signed integer type of 32 bits.