zoneIdentifier Class Reference

Identifies a mesh zone by name and index, with optional physical type and group information. More...

Inheritance diagram for zoneIdentifier:

Public Member Functions

 zoneIdentifier (const zoneIdentifier &)=default
 Copy construct. More...
 
 zoneIdentifier (zoneIdentifier &&)=default
 Move construct. More...
 
zoneIdentifieroperator= (const zoneIdentifier &)=default
 Copy assignment. More...
 
zoneIdentifieroperator= (zoneIdentifier &&)=default
 Move assignment. More...
 
virtual ~zoneIdentifier ()=default
 Destructor. More...
 
 zoneIdentifier ()
 Default construct: name="", index=0. More...
 
 zoneIdentifier (const word &name, const label index)
 Construct from mandatory components. More...
 
 zoneIdentifier (const word &name, const label index, const word &physicalType, const wordList &inGroups=wordList())
 Construct from components. More...
 
 zoneIdentifier (const word &name, const dictionary &dict, const label index)
 Construct from dictionary. More...
 
 zoneIdentifier (const zoneIdentifier &ident, const label newIndex)
 Copy construct, resetting the index (if non-negative) More...
 
 zoneIdentifier (zoneIdentifier &&ident, const label newIndex)
 Move construct, resetting the index (if non-negative) More...
 
const wordname () const noexcept
 The zone name. More...
 
wordname () noexcept
 Modifiable zone name. More...
 
label index () const noexcept
 The index of this zone in the zone list. More...
 
label & index () noexcept
 Modifiable index of this zone in the zone list. More...
 
const wordphysicalType () const noexcept
 The (optional) type of the zone. More...
 
wordphysicalType () noexcept
 Modifiable (optional) type of the zone. More...
 
const wordListinGroups () const noexcept
 The (optional) groups that the zone belongs to. More...
 
wordListinGroups () noexcept
 Modifiable (optional) groups that the zone belongs to. More...
 
bool inGroup (const word &name) const
 True if given name is in a group. More...
 
void addGroup (const word &name)
 Add (unique) group for the zone. More...
 
void removeGroup (const word &name)
 Remove group for the zone. More...
 
void write (Ostream &os) const
 Write (physicalType, inGroups) dictionary entries (without surrounding braces) More...
 

Detailed Description

Identifies a mesh zone by name and index, with optional physical type and group information.

See also
patchIdentifier
Source files

Definition at line 53 of file zoneIdentifier.H.

Constructor & Destructor Documentation

◆ zoneIdentifier() [1/8]

zoneIdentifier ( const zoneIdentifier )
default

Copy construct.

◆ zoneIdentifier() [2/8]

zoneIdentifier ( zoneIdentifier &&  )
default

Move construct.

◆ ~zoneIdentifier()

virtual ~zoneIdentifier ( )
virtualdefault

Destructor.

◆ zoneIdentifier() [3/8]

Default construct: name="", index=0.

Definition at line 26 of file zoneIdentifier.C.

◆ zoneIdentifier() [4/8]

zoneIdentifier ( const word name,
const label  index 
)

Construct from mandatory components.

Definition at line 34 of file zoneIdentifier.C.

◆ zoneIdentifier() [5/8]

zoneIdentifier ( const word name,
const label  index,
const word physicalType,
const wordList inGroups = wordList() 
)

Construct from components.

Definition at line 45 of file zoneIdentifier.C.

◆ zoneIdentifier() [6/8]

zoneIdentifier ( const word name,
const dictionary dict,
const label  index 
)

Construct from dictionary.

Definition at line 60 of file zoneIdentifier.C.

References dict, and dictionary::readIfPresent().

Here is the call graph for this function:

◆ zoneIdentifier() [7/8]

zoneIdentifier ( const zoneIdentifier ident,
const label  newIndex 
)

Copy construct, resetting the index (if non-negative)

Definition at line 74 of file zoneIdentifier.C.

◆ zoneIdentifier() [8/8]

zoneIdentifier ( zoneIdentifier &&  ident,
const label  newIndex 
)

Move construct, resetting the index (if non-negative)

Definition at line 89 of file zoneIdentifier.C.

Member Function Documentation

◆ operator=() [1/2]

zoneIdentifier& operator= ( const zoneIdentifier )
default

Copy assignment.

◆ operator=() [2/2]

zoneIdentifier& operator= ( zoneIdentifier &&  )
default

Move assignment.

◆ name() [1/2]

◆ name() [2/2]

word& name ( )
inlinenoexcept

Modifiable zone name.

Definition at line 169 of file zoneIdentifier.H.

◆ index() [1/2]

label index ( ) const
inlinenoexcept

The index of this zone in the zone list.

Definition at line 174 of file zoneIdentifier.H.

Referenced by cellZone::clone(), pointZone::clone(), and faceZone::clone().

Here is the caller graph for this function:

◆ index() [2/2]

label& index ( )
inlinenoexcept

Modifiable index of this zone in the zone list.

Definition at line 179 of file zoneIdentifier.H.

◆ physicalType() [1/2]

const word& physicalType ( ) const
inlinenoexcept

The (optional) type of the zone.

Definition at line 184 of file zoneIdentifier.H.

◆ physicalType() [2/2]

word& physicalType ( )
inlinenoexcept

Modifiable (optional) type of the zone.

Definition at line 189 of file zoneIdentifier.H.

◆ inGroups() [1/2]

const wordList& inGroups ( ) const
inlinenoexcept

The (optional) groups that the zone belongs to.

Definition at line 194 of file zoneIdentifier.H.

◆ inGroups() [2/2]

wordList& inGroups ( )
inlinenoexcept

Modifiable (optional) groups that the zone belongs to.

Definition at line 199 of file zoneIdentifier.H.

◆ inGroup()

bool inGroup ( const word name) const
inline

True if given name is in a group.

Definition at line 204 of file zoneIdentifier.H.

References UList< T >::contains(), and zoneIdentifier::name().

Here is the call graph for this function:

◆ addGroup()

void addGroup ( const word name)
inline

Add (unique) group for the zone.

Definition at line 212 of file zoneIdentifier.H.

References UList< T >::contains(), zoneIdentifier::name(), and List< T >::push_back().

Here is the call graph for this function:

◆ removeGroup()

void removeGroup ( const word name)

Remove group for the zone.

Definition at line 105 of file zoneIdentifier.C.

References Foam::name().

Here is the call graph for this function:

◆ write()

void write ( Ostream os) const

Write (physicalType, inGroups) dictionary entries (without surrounding braces)

Definition at line 124 of file zoneIdentifier.C.

References Ostream::endEntry(), os(), Ostream::writeEntry(), and Ostream::writeKeyword().

Referenced by Foam::operator<<(), cellZone::writeDict(), pointZone::writeDict(), and faceZone::writeDict().

Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following files: