manualRenumber.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2011-2015 OpenFOAM Foundation
9  Copyright (C) 2022 OpenCFD Ltd.
10 -------------------------------------------------------------------------------
11 License
12  This file is part of OpenFOAM.
13 
14  OpenFOAM is free software: you can redistribute it and/or modify it
15  under the terms of the GNU General Public License as published by
16  the Free Software Foundation, either version 3 of the License, or
17  (at your option) any later version.
18 
19  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22  for more details.
23 
24  You should have received a copy of the GNU General Public License
25  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26 
27 Class
28  Foam::manualRenumber
29 
30 Description
31  Renumber given a ordered-to-original cell association in a file
32 
33 SourceFiles
34  manualRenumber.C
35 
36 \*---------------------------------------------------------------------------*/
37 
38 #ifndef Foam_manualRenumber_H
39 #define Foam_manualRenumber_H
40 
41 #include "renumberMethod.H"
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class manualRenumber Declaration
48 \*---------------------------------------------------------------------------*/
49 
50 class manualRenumber
51 :
52  public renumberMethod
53 {
54  // Private Data
55 
56  fileName dataFile_;
57 
58 
59  // Private Member Functions
60 
61  //- No copy construct
62  manualRenumber(const manualRenumber&) = delete;
63 
64  //- No copy assignment
65  void operator=(const manualRenumber&) = delete;
66 
67 public:
68 
69  //- Runtime type information
70  TypeName("manual");
71 
72 
73  // Constructors
74 
75  //- Construct given the renumber dictionary
76  explicit manualRenumber(const dictionary& dict);
77 
78 
79  //- Destructor
80  virtual ~manualRenumber() = default;
81 
82 
83  // Member Functions
84 
85  //- Return the order in which cells need to be visited
86  //- (ie. from ordered back to original cell label).
87  virtual labelList renumber(const pointField&) const
88  {
90  return labelList();
91  }
92 
93  //- Return the order in which cells need to be visited
94  //- (ie. from ordered back to original cell label).
95  // Uses mesh for regIOobject
96  virtual labelList renumber
97  (
98  const polyMesh& mesh,
99  const pointField& cc
100  ) const;
101 
102  //- Return the order in which cells need to be visited
103  //- (ie. from ordered back to original cell label).
104  virtual labelList renumber
105  (
106  const CompactListList<label>& cellCells,
107  const pointField& cellCentres
108  ) const
109  {
111  return labelList();
112  }
113 
114  //- Return the order in which cells need to be visited
115  //- (ie. from ordered back to original cell label).
116  virtual labelList renumber
117  (
118  const labelListList& cellCells,
119  const pointField& cellCentres
120  ) const
121  {
123  return labelList();
124  }
125 };
126 
127 
128 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
129 
130 } // End namespace Foam
132 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
133 
134 #endif
135 
136 // ************************************************************************* //
dictionary dict
A class for handling file names.
Definition: fileName.H:72
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Definition: dictionary.H:129
TypeName("manual")
Runtime type information.
Abstract base class for renumbering.
dynamicFvMesh & mesh
virtual labelList renumber(const pointField &) const
Return the order in which cells need to be visited (ie. from ordered back to original cell label)...
Renumber given a ordered-to-original cell association in a file.
A packed storage of objects of type <T> using an offset table for access.
virtual ~manualRenumber()=default
Destructor.
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:74
List< label > labelList
A List of labels.
Definition: List.H:62
#define NotImplemented
Issue a FatalErrorIn for a function not currently implemented.
Definition: error.H:686
Namespace for OpenFOAM.