Initialise the NamedEnum HashTable from the static list of names. More...
Inherits HashTable< int >.
Public Member Functions | |
NamedEnum () | |
Construct from names. More... | |
Enum | read (Istream &) const |
Read a word from Istream and return the corresponding. More... | |
void | write (const Enum e, Ostream &) const |
Write the name representation of the enumeration to an Ostream. More... | |
const Enum | operator[] (const char *name) const |
Return the enumeration element corresponding to the given name. More... | |
const Enum | operator[] (const word &name) const |
Return the enumeration element corresponding to the given name. More... | |
const char * | operator[] (const Enum e) const |
Return the name of the given enumeration element. More... | |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
const char * | names [] |
![]() | |
bool | set (const Key &, const T &newElmt) |
Assign a new hashedEntry, overwriting existing entries. More... | |
HashTable (const label size=128) | |
Construct given initial table size. More... | |
HashTable (Istream &, const label size=128) | |
Construct from Istream. More... | |
HashTable (const HashTable< T, Key, Hash > &) | |
Construct as copy. More... | |
HashTable (const Xfer< HashTable< T, Key, Hash > > &) | |
Construct by transferring the parameter contents. More... | |
~HashTable () | |
Destructor. More... | |
label | capacity () const |
The size of the underlying table. More... | |
label | size () const |
Return number of elements in table. More... | |
bool | empty () const |
Return true if the hash table is empty. More... | |
bool | found (const Key &) const |
Return true if hashedEntry is found in table. More... | |
iterator | find (const Key &) |
Find and return an iterator set at the hashedEntry. More... | |
const_iterator | find (const Key &) const |
Find and return an const_iterator set at the hashedEntry. More... | |
List< Key > | toc () const |
Return the table of contents. More... | |
List< Key > | sortedToc () const |
Return the table of contents as a sorted list. More... | |
Ostream & | printInfo (Ostream &) const |
Print information. More... | |
bool | insert (const Key &, const T &newElmt) |
Insert a new hashedEntry. More... | |
bool | erase (const iterator &) |
Erase a hashedEntry specified by given iterator. More... | |
bool | erase (const Key &) |
Erase a hashedEntry specified by the given key. More... | |
label | erase (const UList< Key > &) |
Remove entries given by the listed keys from this HashTable. More... | |
label | erase (const HashTable< AnyType, Key, AnyHash > &) |
Remove entries given by the given keys from this HashTable. More... | |
Foam::label | erase (const HashTable< AnyType, Key, AnyHash > &rhs) |
void | resize (const label newSize) |
Resize the hash table for efficiency. More... | |
void | clear () |
Clear all entries from table. More... | |
void | clearStorage () |
Clear the table entries and the table itself. More... | |
void | shrink () |
Shrink the allocated table to approx. twice number of elements. More... | |
void | transfer (HashTable< T, Key, Hash > &) |
Transfer the contents of the argument table into this table. More... | |
Xfer< HashTable< T, Key, Hash > > | xfer () |
Transfer contents to the Xfer container. More... | |
T & | operator[] (const Key &) |
Find and return a hashedEntry. More... | |
const T & | operator[] (const Key &) const |
Find and return a hashedEntry. More... | |
T & | operator() (const Key &) |
Find and return a hashedEntry, create it null if not present. More... | |
void | operator= (const HashTable< T, Key, Hash > &) |
Assignment. More... | |
bool | operator== (const HashTable< T, Key, Hash > &) const |
Equality. Hash tables are equal if the keys and values are equal. More... | |
bool | operator!= (const HashTable< T, Key, Hash > &) const |
The opposite of the equality operation. Takes linear time. More... | |
iterator | begin () |
Iterator set to the beginning of the HashTable. More... | |
const_iterator | begin () const |
const_iterator set to the beginning of the HashTable More... | |
const_iterator | cbegin () const |
const_iterator set to the beginning of the HashTable More... | |
Static Public Member Functions | |
static stringList | strings () |
The set of names as a list of strings. More... | |
static wordList | words () |
The set of names as a list of words. More... | |
Static Public Attributes | |
static const char * | names [nEnum] |
The set of names corresponding to the enumeration Enum. More... | |
Private Member Functions | |
StaticAssert (nEnum > 0) | |
nEnum must be positive (non-zero) More... | |
NamedEnum (const NamedEnum &) | |
Disallow default bitwise copy construct. More... | |
void | operator= (const NamedEnum &) |
Disallow default bitwise assignment. More... | |
Additional Inherited Members | |
![]() | |
typedef T | value_type |
Type of values the HashTable contains. More... | |
typedef T & | reference |
Type that can be used for storing into HashTable::value_type. More... | |
typedef label | size_type |
The type that can represent the size of a HashTable. More... | |
![]() | |
const typedef T & | const_reference |
Type that can be used for storing into constant. More... | |
Initialise the NamedEnum HashTable from the static list of names.
Definition at line 52 of file NamedEnum.H.
Construct from names.
Definition at line 31 of file NamedEnum.C.
|
private |
nEnum must be positive (non-zero)
Enum read | ( | Istream & | is | ) | const |
Read a word from Istream and return the corresponding.
enumeration element
Definition at line 61 of file NamedEnum.C.
Referenced by nastranSurfaceWriter::nastranSurfaceWriter(), distributedTriSurfaceMesh::read(), solidificationMeltingSource::read(), scene::readCamera(), addfileModificationCheckingToOpt::readData(), addcommsTypeToOpt::readData(), and Time::readDict().
void write | ( | const Enum | e, |
Ostream & | os | ||
) | const |
Write the name representation of the enumeration to an Ostream.
Definition at line 79 of file NamedEnum.C.
|
static |
The set of names as a list of strings.
Definition at line 86 of file NamedEnum.C.
|
static |
The set of names as a list of words.
Definition at line 105 of file NamedEnum.C.
Referenced by mappedPatchBase::mappedPatchBase().
|
inline |
Return the enumeration element corresponding to the given name.
Definition at line 101 of file NamedEnum.H.
Return the enumeration element corresponding to the given name.
Definition at line 107 of file NamedEnum.H.
|
inline |
Return the name of the given enumeration element.
Definition at line 113 of file NamedEnum.H.
const char * names |
Definition at line 46 of file directions.C.
const char * names |
Definition at line 41 of file tetDecomposer.C.
const char * names |
Definition at line 54 of file slidingInterface.C.
const char * names |
Definition at line 49 of file extendedEdgeMesh.C.
const char * names |
Definition at line 62 of file extendedEdgeMesh.C.
const char * names |
Definition at line 77 of file extendedEdgeMesh.C.
const char * names |
Definition at line 37 of file coordSet.C.
const char * names |
Definition at line 41 of file vtkUnstructuredReader.C.
const char * names |
Definition at line 58 of file vtkUnstructuredReader.C.
const char * names |
Definition at line 70 of file vtkUnstructuredReader.C.
const char * names |
Definition at line 40 of file fanPressureFvPatchScalarField.C.
const char * names |
Definition at line 45 of file waveSurfacePressureFvPatchScalarField.C.
const char * names |
Definition at line 44 of file surfaceDisplacementPointPatchVectorField.C.
const char * names |
Definition at line 43 of file surfaceSlipDisplacementPointPatchVectorField.C.
const char * names |
Definition at line 47 of file cellSetOption.C.
const char * names |
Definition at line 69 of file directionalPressureGradientExplicitSource.C.
const char * names |
Definition at line 43 of file solidificationMeltingSource.C.
const char * names |
Definition at line 50 of file tabulatedNTUHeatTransfer.C.
const char * names |
Definition at line 39 of file refineImmersedBoundaryMesh.C.
const char * names |
Definition at line 37 of file phaseProperties.C.
const char * names |
Definition at line 72 of file meshRefinement.C.
const char * names |
Definition at line 87 of file meshRefinement.C.
const char * names |
Definition at line 97 of file meshRefinement.C.
const char * names |
Definition at line 41 of file surfaceZonesInfo.C.
const char * names |
Definition at line 60 of file surfaceZonesInfo.C.
const char * names |
Definition at line 45 of file shellSurfaces.C.
const char * names |
Definition at line 33 of file faceAreaIntersect.C.
const char * names |
Definition at line 57 of file mappedPatchBase.C.
const char * names |
Definition at line 72 of file mappedPatchBase.C.
const char * names |
Definition at line 45 of file faceToCell.C.
const char * names |
Definition at line 44 of file faceZoneToCell.C.
const char * names |
Definition at line 45 of file pointToCell.C.
const char * names |
Definition at line 46 of file cellToFace.C.
const char * names |
Definition at line 45 of file pointToFace.C.
const char * names |
Definition at line 45 of file cellToPoint.C.
const char * names |
Definition at line 45 of file faceToPoint.C.
const char * names |
Definition at line 43 of file topoSetSource.C.
const char * names |
Definition at line 45 of file booleanSurface.C.
const char * names |
Definition at line 37 of file volumeType.C.
const char * names |
Definition at line 43 of file UPstream.C.
const char * names |
Definition at line 42 of file regIOobject.C.
const char * names |
Definition at line 40 of file coupledPolyPatch.C.
const char * names |
Definition at line 39 of file intersection.C.
const char * names |
Definition at line 50 of file intersection.C.
const char * names |
Definition at line 60 of file fileMonitor.C.
const char * names |
Definition at line 60 of file distributedTriSurfaceMesh.C.
const char * names |
Definition at line 40 of file fieldAverageItem.C.
const char * names |
Definition at line 40 of file fieldMinMax.C.
const char * names |
Definition at line 36 of file cellSource.C.
const char * names |
Definition at line 44 of file cellSource.C.
const char * names |
Definition at line 42 of file faceSource.C.
const char * names |
Definition at line 51 of file faceSource.C.
const char * names |
Definition at line 43 of file fieldValueDelta.C.
const char * names |
Definition at line 51 of file fieldVisualisationBase.C.
const char * names |
Definition at line 58 of file fieldVisualisationBase.C.
const char * names |
Definition at line 38 of file geometryBase.C.
const char * names |
Definition at line 44 of file pathline.C.
const char * names |
Definition at line 44 of file pointData.C.
const char * names |
Definition at line 50 of file abortCalculation.C.
const char * names |
Definition at line 48 of file equationInitialResidualCondition.C.
const char * names |
Definition at line 52 of file minMaxCondition.C.
const char * names |
Definition at line 48 of file fluxSummary.C.
const char * names |
Definition at line 38 of file turbulenceFields.C.
const char * names |
Definition at line 53 of file turbulenceFields.C.
const char * names |
Definition at line 40 of file energyRegionCoupledFvPatchScalarField.C.
const char * names |
Definition at line 42 of file meshToMesh.C.
const char * names |
Definition at line 49 of file sampledTriSurfaceMesh.C.
const char * names |
Definition at line 42 of file nastranSurfaceWriter.C.
const char * names |
Definition at line 54 of file nastranSurfaceWriter.C.
const char * names |
Definition at line 45 of file humidityTemperatureCoupledMixedFvPatchScalarField.C.
const char * names |
Definition at line 43 of file boundaryRadiationPropertiesFvPatchField.C.
const char * names |
Definition at line 41 of file solarCalculator.C.
const char * names |
Definition at line 52 of file solarCalculator.C.
const char * names |
Definition at line 42 of file alphaContactAngleFvPatchScalarField.C.
const char * names |
Definition at line 42 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.
const char * names |
Definition at line 41 of file temperatureCoupledBase.C.
const char * names |
Definition at line 43 of file turbulentHeatFluxTemperatureFvPatchScalarField.C.
const char * names |
Definition at line 44 of file turbulentHeatFluxTemperatureFvPatchScalarField.C.
const char * names |
Definition at line 49 of file Test-namedEnum.C.
const char * names |
Definition at line 68 of file extrudeMesh.C.
const char * names |
Definition at line 72 of file extrudeMesh.C.
const char * names |
Definition at line 72 of file extrudeMesh.C.
const char * names |
Definition at line 40 of file bak_turbulentHeatFluxTemperatureFvPatchScalarField.C.
|
static |
The set of names corresponding to the enumeration Enum.
Definition at line 73 of file NamedEnum.H.
Referenced by NamedEnum< directionType, 3 >::operator[]().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.