Back to index

salome-smesh  6.5.0
Public Member Functions | Static Public Member Functions | Private Member Functions | Static Private Member Functions
VISCOUS::_ViscousListener Class Reference

Listener of events of 3D sub-meshes computed with viscous layers. More...

List of all members.

Public Member Functions

virtual void ProcessEvent (const int event, const int eventType, SMESH_subMesh *subMesh, SMESH_subMeshEventListenerData *data, const SMESH_Hypothesis *hyp)

Static Public Member Functions

static _MeshOfSolidGetSolidMesh (SMESH_Mesh *mesh, const TopoDS_Shape &solid, bool toCreate=false)
static void RemoveSolidMesh (SMESH_Mesh *mesh, const TopoDS_Shape &solid)

Private Member Functions

 _ViscousListener ()

Static Private Member Functions

static SMESH_subMeshEventListener * Get ()

Detailed Description

Listener of events of 3D sub-meshes computed with viscous layers.

It is used to store data computed by _ViscousBuilder for a sub-mesh and to delete the data as soon as it has been used

Definition at line 166 of file StdMeshers_ViscousLayers.cxx.

Constructor & Destructor Documentation

Definition at line 168 of file StdMeshers_ViscousLayers.cxx.

                                 "StdMeshers_ViscousLayers::_ViscousListener") {}

Member Function Documentation

static SMESH_subMeshEventListener* VISCOUS::_ViscousListener::Get ( ) [inline, static, private]

Definition at line 171 of file StdMeshers_ViscousLayers.cxx.

{ static _ViscousListener l; return &l; }
static _MeshOfSolid* VISCOUS::_ViscousListener::GetSolidMesh ( SMESH_Mesh *  mesh,
const TopoDS_Shape &  solid,
bool  toCreate = false 
) [inline, static]

Definition at line 186 of file StdMeshers_ViscousLayers.cxx.

      if ( !mesh ) return 0;
      SMESH_subMesh* sm = mesh->GetSubMesh(solid);
      _MeshOfSolid* data = (_MeshOfSolid*) sm->GetEventListenerData( Get() );
      if ( !data && toCreate )
        data = new _MeshOfSolid(mesh);
        data->mySubMeshes.push_back( sm ); // to find SOLID by _MeshOfSolid
        sm->SetEventListener( Get(), data, sm );
      return data;

Here is the caller graph for this function:

virtual void VISCOUS::_ViscousListener::ProcessEvent ( const int  event,
const int  eventType,
SMESH_subMesh *  subMesh,
SMESH_subMeshEventListenerData data,
const SMESH_Hypothesis *  hyp 
) [inline, virtual]

Definition at line 173 of file StdMeshers_ViscousLayers.cxx.

      if ( SMESH_subMesh::COMPUTE_EVENT == eventType )
        // delete SMESH_ProxyMesh containing temporary faces
        subMesh->DeleteEventListener( this );
static void VISCOUS::_ViscousListener::RemoveSolidMesh ( SMESH_Mesh *  mesh,
const TopoDS_Shape &  solid 
) [inline, static]

Definition at line 202 of file StdMeshers_ViscousLayers.cxx.

      mesh->GetSubMesh(solid)->DeleteEventListener( _ViscousListener::Get() );

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