Skip to content

Commit e92559a

Browse files
Merge pull request #1740 from arcaneframework/dev/gg-move-itembase-out-of-impl-namespace
Move classes 'ItemBase' and 'MutableItemBase' in public API
2 parents 1824fd9 + d1489a4 commit e92559a

File tree

6 files changed

+40
-54
lines changed

6 files changed

+40
-54
lines changed

arcane/src/arcane/core/ItemInternal.h

+10-25
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,6 @@
4444
/*---------------------------------------------------------------------------*/
4545
/*---------------------------------------------------------------------------*/
4646

47-
namespace Arcane::impl
48-
{
49-
class ItemBase;
50-
}
51-
5247
namespace Arcane::mesh
5348
{
5449
class IncrementalItemConnectivityBase;
@@ -95,7 +90,7 @@ class ARCANE_CORE_EXPORT ItemInternalConnectivityList
9590
// IMPORTANT: Cette structure doit avoir le même agencement mémoire
9691
// que la structure C# de même nom.
9792

98-
friend class impl::ItemBase;
93+
friend class ItemBase;
9994
friend class ItemInternal;
10095
friend class Item;
10196

@@ -415,11 +410,6 @@ class ARCANE_CORE_EXPORT ItemInternalConnectivityList
415410
#endif
416411
};
417412

418-
/*---------------------------------------------------------------------------*/
419-
/*---------------------------------------------------------------------------*/
420-
421-
namespace impl
422-
{
423413
/*---------------------------------------------------------------------------*/
424414
/*---------------------------------------------------------------------------*/
425415
/*!
@@ -685,15 +675,15 @@ class ARCANE_CORE_EXPORT ItemBase
685675
* se traduit par un débordement de tableau.
686676
*/
687677
//@{
688-
ItemIndexedListView<DynExtent> nodeList() const { return _connectivity()->nodeList(m_local_id); }
689-
ItemIndexedListView<DynExtent> edgeList() const { return _connectivity()->edgeList(m_local_id); }
690-
ItemIndexedListView<DynExtent> faceList() const { return _connectivity()->faceList(m_local_id); }
691-
ItemIndexedListView<DynExtent> cellList() const { return _connectivity()->cellList(m_local_id); }
692-
693-
ItemIndexedListView<DynExtent> itemList(Node*) const { return nodeList(); }
694-
ItemIndexedListView<DynExtent> itemList(Edge*) const { return edgeList(); }
695-
ItemIndexedListView<DynExtent> itemList(Face*) const { return faceList(); }
696-
ItemIndexedListView<DynExtent> itemList(Cell*) const { return cellList(); }
678+
impl::ItemIndexedListView<DynExtent> nodeList() const { return _connectivity()->nodeList(m_local_id); }
679+
impl::ItemIndexedListView<DynExtent> edgeList() const { return _connectivity()->edgeList(m_local_id); }
680+
impl::ItemIndexedListView<DynExtent> faceList() const { return _connectivity()->faceList(m_local_id); }
681+
impl::ItemIndexedListView<DynExtent> cellList() const { return _connectivity()->cellList(m_local_id); }
682+
683+
impl::ItemIndexedListView<DynExtent> itemList(Node*) const { return nodeList(); }
684+
impl::ItemIndexedListView<DynExtent> itemList(Edge*) const { return edgeList(); }
685+
impl::ItemIndexedListView<DynExtent> itemList(Face*) const { return faceList(); }
686+
impl::ItemIndexedListView<DynExtent> itemList(Cell*) const { return cellList(); }
697687
//@}
698688

699689
ItemBase nodeBase(Int32 index) const { return _connectivity()->nodeBase(m_local_id,index); }
@@ -892,11 +882,6 @@ class ARCANE_CORE_EXPORT MutableItemBase
892882
inline void _setFaceInfos(Int32 mod_flags);
893883
};
894884

895-
/*---------------------------------------------------------------------------*/
896-
/*---------------------------------------------------------------------------*/
897-
898-
} // End namespace impl
899-
900885
/*---------------------------------------------------------------------------*/
901886
/*---------------------------------------------------------------------------*/
902887
/*!

arcane/src/arcane/core/ItemInternalVectorView.h

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
22
//-----------------------------------------------------------------------------
3-
// Copyright 2000-2023 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
3+
// Copyright 2000-2024 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
44
// See the top-level COPYRIGHT file for details.
55
// SPDX-License-Identifier: Apache-2.0
66
//-----------------------------------------------------------------------------
77
/*---------------------------------------------------------------------------*/
8-
/* ItemInternalVectorView.h (C) 2000-2023 */
8+
/* ItemInternalVectorView.h (C) 2000-2024 */
99
/* */
1010
/* Vue sur un vecteur (tableau indirect) d'entités. */
1111
/*---------------------------------------------------------------------------*/
12-
#ifndef ARCANE_ITEMINTERNALVECTORVIEW_H
13-
#define ARCANE_ITEMINTERNALVECTORVIEW_H
12+
#ifndef ARCANE_CORE_ITEMINTERNALVECTORVIEW_H
13+
#define ARCANE_CORE_ITEMINTERNALVECTORVIEW_H
1414
/*---------------------------------------------------------------------------*/
1515
/*---------------------------------------------------------------------------*/
1616

1717
#include "arcane/utils/ArrayView.h"
18-
#include "arcane/ItemTypes.h"
19-
#include "arcane/ItemSharedInfo.h"
20-
#include "arcane/ItemIndexedListView.h"
18+
#include "arcane/core/ItemTypes.h"
19+
#include "arcane/core/ItemSharedInfo.h"
20+
#include "arcane/core/ItemIndexedListView.h"
2121

2222
#include <iterator>
2323

@@ -126,7 +126,7 @@ class ARCANE_CORE_EXPORT ItemInternalVectorView
126126

127127
friend class ItemVectorView;
128128
friend class ItemInternalConnectivityList;
129-
friend class impl::ItemBase;
129+
friend class ItemBase;
130130
friend class ItemEnumeratorBase;
131131
friend class SimdItemEnumeratorBase;
132132
friend class ItemInternalEnumerator;

arcane/src/arcane/core/ItemSharedInfo.h

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
22
//-----------------------------------------------------------------------------
3-
// Copyright 2000-2023 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
3+
// Copyright 2000-2024 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
44
// See the top-level COPYRIGHT file for details.
55
// SPDX-License-Identifier: Apache-2.0
66
//-----------------------------------------------------------------------------
77
/*---------------------------------------------------------------------------*/
8-
/* ItemSharedInfo.h (C) 2000-2023 */
8+
/* ItemSharedInfo.h (C) 2000-2024 */
99
/* */
1010
/* Informations communes à plusieurs entités. */
1111
/*---------------------------------------------------------------------------*/
12-
#ifndef ARCANE_ITEMSHAREDINFO_H
13-
#define ARCANE_ITEMSHAREDINFO_H
12+
#ifndef ARCANE_CORE_ITEMSHAREDINFO_H
13+
#define ARCANE_CORE_ITEMSHAREDINFO_H
1414
/*---------------------------------------------------------------------------*/
1515
/*---------------------------------------------------------------------------*/
1616

17-
#include "arcane/ArcaneTypes.h"
18-
#include "arcane/ItemTypes.h"
19-
#include "arcane/ItemTypeInfo.h"
20-
#include "arcane/MeshItemInternalList.h"
17+
#include "arcane/core/ArcaneTypes.h"
18+
#include "arcane/core/ItemTypes.h"
19+
#include "arcane/core/ItemTypeInfo.h"
20+
#include "arcane/core/MeshItemInternalList.h"
2121

2222
/*---------------------------------------------------------------------------*/
2323
/*---------------------------------------------------------------------------*/
@@ -53,8 +53,8 @@ class ItemInternalConnectivityList;
5353
*/
5454
class ARCANE_CORE_EXPORT ItemSharedInfo
5555
{
56-
friend class impl::ItemBase;
57-
friend class impl::MutableItemBase;
56+
friend class ItemBase;
57+
friend class MutableItemBase;
5858
friend class Item;
5959
friend class ItemGenericInfoListView;
6060
friend class ItemInternal;

arcane/src/arcane/core/ItemTypes.h

+4-2
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,12 @@ class DoF;
5959
class Item;
6060
class ItemWithNodes;
6161
class ItemInternal;
62-
namespace impl
63-
{
6462
class ItemBase;
6563
class MutableItemBase;
64+
namespace impl
65+
{
66+
using ItemBase = ::Arcane::ItemBase;
67+
using MutableItemBase = ::Arcane::MutableItemBase;
6668
template<int Extent = DynExtent> class ItemIndexedListView;
6769
class ItemLocalIdListContainerView;
6870
}

arcane/src/arcane/core/MeshItemInternalList.h

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
22
//-----------------------------------------------------------------------------
3-
// Copyright 2000-2022 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
3+
// Copyright 2000-2024 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
44
// See the top-level COPYRIGHT file for details.
55
// SPDX-License-Identifier: Apache-2.0
66
//-----------------------------------------------------------------------------
77
/*---------------------------------------------------------------------------*/
8-
/* MeshItemInternalList.h (C) 2000-2022 */
8+
/* MeshItemInternalList.h (C) 2000-2024 */
99
/* */
1010
/* Tableaux d'indirection sur les entités d'un maillage. */
1111
/*---------------------------------------------------------------------------*/
12-
#ifndef ARCANE_MESHITEMINTERNALLIST_H
13-
#define ARCANE_MESHITEMINTERNALLIST_H
12+
#ifndef ARCANE_CORE_MESHITEMINTERNALLIST_H
13+
#define ARCANE_CORE_MESHITEMINTERNALLIST_H
1414
/*---------------------------------------------------------------------------*/
1515
/*---------------------------------------------------------------------------*/
1616

1717
#include "arcane/utils/ArrayView.h"
18-
#include "arcane/ItemTypes.h"
18+
#include "arcane/core/ItemTypes.h"
1919

2020
/*---------------------------------------------------------------------------*/
2121
/*---------------------------------------------------------------------------*/
@@ -83,7 +83,7 @@ class ARCANE_CORE_EXPORT MeshItemInternalList
8383
friend class mesh::PolyhedralMesh;
8484

8585
friend class ItemInternalConnectivityList;
86-
friend class impl::ItemBase;
86+
friend class ItemBase;
8787

8888
public:
8989

arcane/src/arcane/core/materials/MaterialsCoreGlobal.h

+2-3
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,13 @@
3131
/*---------------------------------------------------------------------------*/
3232
/*---------------------------------------------------------------------------*/
3333

34-
namespace Arcane::impl
34+
namespace Arcane
3535
{
3636
class ItemBase;
3737
}
38-
3938
namespace Arcane::Materials::matimpl
4039
{
41-
using Arcane::impl::ItemBase;
40+
using ::Arcane::ItemBase;
4241
class ConstituentItemBase;
4342
}
4443

0 commit comments

Comments
 (0)