Pointwise Plugin SDK
Public Member Functions | Protected Member Functions | List of all members

The structured boundary group class. More...

#include <CaeStrBoundaryGroup.h>

+ Inheritance diagram for CaeStrBoundaryGroup:

Public Member Functions

PWP_UINT32 boundaryCount () const
 Get the number of boundaries in the group. More...
 
PWGM_HBNDRY enumBoundaries (PWP_UINT32 ndx) const
 Get a boundary in the group. More...
 
PWGM_HBNDRY firstBoundary () const
 Get the first boundary in the group. More...
 
virtual ~CaeStrBoundaryGroup ()
 Destructor. More...
 

Protected Member Functions

virtual PWP_UINT32 boundaryCountImpl () const =0
 Get the number of boundaries in the group. More...
 
virtual PWGM_HBNDRY enumBoundariesImpl (PWP_UINT32 ndx) const =0
 Get a boundary in the group. More...
 

Detailed Description

The structured boundary group class.

The CaeStrBoundaryGroup class defines the required interface for a collection of PWGM_HBNDRY handles. This interface presents the boundary collection as a sequential array. The boundaries are addressed using an index from 0 to boundaryCount() - 1.

The public interface provides three methods; boundaryCount(), enumBoundaries(), and firstBoundary(). These methods use two protected virtual methods to implement the behavior.

A boundary group subclass must inherit CaeStrBoundaryGroup and implement its two pure virtual methods; boundaryCountImpl() and enumBoundariesImpl(). This abstraction lets boundary group subclasses store the PWGM_HBNDRY handles any way it needs as long as they can be addressed sequentially.

Sample Usage:

The following snippet is extracted from CaeStrBlock.

virtual PWP_UINT32 boundaryCountImpl() const {
return PwBlkBoundaryCount(block_);
}
return PwBlkEnumBoundaries(block_, ndx);
}
See also
CaeStrBlock, CaeStrGridModel.

Definition at line 45 of file CaeStrBoundaryGroup.h.

Constructor & Destructor Documentation

◆ ~CaeStrBoundaryGroup()

virtual CaeStrBoundaryGroup::~CaeStrBoundaryGroup ( )
inlinevirtual

Destructor.

Definition at line 49 of file CaeStrBoundaryGroup.h.

Member Function Documentation

◆ boundaryCount()

PWP_UINT32 CaeStrBoundaryGroup::boundaryCount ( ) const
inline

Get the number of boundaries in the group.

Returns
The total number of boundaries in the group.

Definition at line 57 of file CaeStrBoundaryGroup.h.

References boundaryCountImpl().

◆ boundaryCountImpl()

virtual PWP_UINT32 CaeStrBoundaryGroup::boundaryCountImpl ( ) const
protectedpure virtual

Get the number of boundaries in the group.

Boundary group subclasses must implement this pure virtual method.

Returns
The total number of boundaries in the group.

Referenced by boundaryCount().

◆ enumBoundaries()

PWGM_HBNDRY CaeStrBoundaryGroup::enumBoundaries ( PWP_UINT32  ndx) const
inline

Get a boundary in the group.

Parameters
ndxThe boundary's sequential index.
Returns
The boundary's PWGM_HBNDRY. If ndx is invalid, the returned handle is invalid.
See also
PWGM_HBNDRY, PWGM_HBNDRY_ISVALID()

Definition at line 68 of file CaeStrBoundaryGroup.h.

References enumBoundariesImpl().

Referenced by CaeStrBoundary::moveFirst(), and CaeStrBoundary::moveTo().

◆ enumBoundariesImpl()

virtual PWGM_HBNDRY CaeStrBoundaryGroup::enumBoundariesImpl ( PWP_UINT32  ndx) const
protectedpure virtual

Get a boundary in the group.

Boundary group subclasses must implement this pure virtual method.

Parameters
ndxThe boundary's sequential index.
Returns
The boundary's PWGM_HBNDRY. If ndx is invalid, the returned handle is invalid.
See also
PWGM_HBNDRY, PWGM_HBNDRY_ISVALID()

Referenced by enumBoundaries(), and firstBoundary().

◆ firstBoundary()

PWGM_HBNDRY CaeStrBoundaryGroup::firstBoundary ( ) const
inline

Get the first boundary in the group.

Returns
The boundary's PWGM_HBNDRY. If the group is empty, the returned handle is invalid.
Note
Equivalent to enumBoundaries(0)
See also
PWGM_HBNDRY, PWGM_HBNDRY_ISVALID()

Definition at line 79 of file CaeStrBoundaryGroup.h.

References enumBoundariesImpl().


The documentation for this class was generated from the following file:
PWP_UINT32
unsigned int PWP_UINT32
32-bit unsigned integer
Definition: apiPWP.h:210
CaeStrBoundaryGroup::boundaryCountImpl
virtual PWP_UINT32 boundaryCountImpl() const =0
Get the number of boundaries in the group.
PwBlkEnumBoundaries
PWGM_HBNDRY PwBlkEnumBoundaries(PWGM_HBLOCK block, PWP_UINT32 ndx)
Sequentially enumerate the block's boundaries.
Definition: apiGridModel.cxx:571
PWGM_HBNDRY
An opaque handle to a structured block boundary.
Definition: apiGridModel.h:457
CaeStrBoundaryGroup::enumBoundariesImpl
virtual PWGM_HBNDRY enumBoundariesImpl(PWP_UINT32 ndx) const =0
Get a boundary in the group.
PwBlkBoundaryCount
PWP_UINT32 PwBlkBoundaryCount(PWGM_HBLOCK block)
Get the number of boundaries in the block.
Definition: apiGridModel.cxx:563