Version: 6.5.0
Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Friends | List of all members
MEDMEM::SUPPORT Class Reference
Collaboration diagram for MEDMEM::SUPPORT:
Collaboration graph
[legend]

Public Member Functions

 SUPPORT ()
 SUPPORT (const SUPPORT &m)
SUPPORToperator= (const SUPPORT &support)
bool operator== (const SUPPORT &support) const
bool deepCompare (const SUPPORT &support) const
void update ()
void setName (const std::string &Name)
void setDescription (const std::string &Description)
void setMesh (const GMESH *Mesh) const
void setMeshName (const string &meshName)
void setAll (bool All)
void setEntity (MED_EN::medEntityMesh Entity)
void setNumberOfGeometricType (int NumberOfGeometricType)
void setGeometricType (const MED_EN::medGeometryElement *GeometricType)
void setNumberOfElements (const int *NumberOfElements)
void setNumber (MEDSKYLINEARRAY *Number)
void setNumber (const int *index, const int *value, bool shallowCopy=false)
const std::string & getName () const
const std::string & getDescription () const
virtual const GMESHgetMesh () const
std::string getMeshName () const
MED_EN::medEntityMesh getEntity () const
bool isOnAllElements () const
int getNumberOfTypes () const
const MED_EN::medGeometryElement * getTypes () const
int getNumberOfElements (MED_EN::medGeometryElement GeometricType) const throw (MEDEXCEPTION)
const int * getNumberOfElements () const throw (MEDEXCEPTION)
virtual MEDSKYLINEARRAY * getnumber () const throw (MEDEXCEPTION)
virtual MEDSKYLINEARRAY * getnumberFromFile () const throw (MEDEXCEPTION)
virtual const int * getNumber (MED_EN::medGeometryElement GeometricType) const throw (MEDEXCEPTION)
virtual const int * getNumberFromFile (MED_EN::medGeometryElement GeometricType) const throw (MEDEXCEPTION)
virtual const int * getNumberIndex () const throw (MEDEXCEPTION)
virtual int getValIndFromGlobalNumber (const int number) const throw (MEDEXCEPTION)
void blending (const SUPPORT *mySupport) throw (MEDEXCEPTION)
void setpartial (const std::string &Description, int NumberOfGeometricType, int TotalNumberOfEntity, const MED_EN::medGeometryElement *GeometricType, const int *NumberOfEntity, const int *NumberValue)
void setpartial (MEDSKYLINEARRAY *number, bool shallowCopy=false) throw (MEDEXCEPTION)
void setpartial_fromfile (MEDSKYLINEARRAY *number, bool shallowCopy=false) throw (MEDEXCEPTION)
void setProfilNames (const std::vector< std::string > &profilNames) throw (MEDEXCEPTION)
std::vector< std::string > getProfilNames () const throw (MEDEXCEPTION)
void getBoundaryElements () throw (MEDEXCEPTION)
void changeElementsNbs (MED_EN::medEntityMesh entity, const int *renumberingFromOldToNew)
void intersecting (const SUPPORT *mySupport) throw (MEDEXCEPTION)
bool belongsTo (const SUPPORT &other, bool deepCompare=false) const
SUPPORTgetComplement () const
SUPPORTsubstract (const SUPPORT &other) const throw (MEDEXCEPTION)
SUPPORTgetBoundaryElements (MED_EN::medEntityMesh Entity) const throw (MEDEXCEPTION)
SUPPORTbuildSupportOnNode () const throw (MEDEXCEPTION)
void fillFromNodeList (const std::list< int > &listOfNode) throw (MEDEXCEPTION)
void fillFromElementList (const std::list< int > &listOfElt) throw (MEDEXCEPTION)
void clearDataOnNumbers ()
MESHmakeMesh () const

Protected Member Functions

virtual ~SUPPORT ()

Static Protected Member Functions

static std::list< int > * sub (int start, int end, const int *idsToSuppress, int lgthIdsToSuppress)
static std::list< int > * sub (const int *ids, int lgthIds, const int *idsToSuppress, int lgthIdsToSuppress)

Protected Attributes

std::string _name
std::string _meshName
std::string _description
const GMESH_mesh
MED_EN::medEntityMesh _entity
int _numberOfGeometricType
PointerOf
< MED_EN::medGeometryElement > 
_geometricType
bool _isOnAllElts
PointerOf< int > _numberOfElements
int _totalNumberOfElements
MEDSKYLINEARRAY * _number
MEDSKYLINEARRAY * _number_fromfile
std::vector< std::string > _profilNames

Friends

MEDMEM_EXPORT ostream & operator<< (ostream &os, const SUPPORT &my)

Detailed Description

This class describe a support of elements on an entity of the mesh.

It contains the list of meshes elements for an entity (MED_NODE, MED_CELL, MED_FACE or MED_EDGE).

Examples:
FIELDcreate.cxx.

Constructor & Destructor Documentation

SUPPORT::SUPPORT ( )

Constructor.

Referenced by buildSupportOnNode().

SUPPORT::~SUPPORT ( )
protectedvirtual

Destructor.

References _mesh, and clearDataOnNumbers().

Member Function Documentation

SUPPORT & SUPPORT::operator= ( const SUPPORT m)
bool MEDMEM::SUPPORT::operator== ( const SUPPORT support) const

operator == This operator does not compare attributs _name and _description.

bool MEDMEM::SUPPORT::deepCompare ( const SUPPORT support) const

operator == + in case false a test if coordinates and connectivity of _mesh and support->_mesh are the same

References _entity, _geometricType, _isOnAllElts, _mesh, _numberOfElements, _numberOfGeometricType, _totalNumberOfElements, and getNumber().

void SUPPORT::update ( )
void MEDMEM::SUPPORT::setName ( const std::string &  Name)
void MEDMEM::SUPPORT::setDescription ( const std::string &  Description)

set the attribute _description to Description

void SUPPORT::setMesh ( const GMESH Mesh) const
void SUPPORT::setMeshName ( const string &  meshName)

set the meshName if there is ni reference _mesh to Mesh

References _mesh, and _meshName.

void SUPPORT::setEntity ( MED_EN::medEntityMesh  Entity)
void SUPPORT::setNumberOfGeometricType ( int  NumberOfGeometricType)

set the attribute _numberOfGeometricType to NumberOfGeometricType

References _geometricType, _numberOfElements, and _profilNames.

Referenced by getBoundaryElements(), MEDMEM::MESH::getSkin(), and update().

void SUPPORT::setGeometricType ( const MED_EN::medGeometryElement *  GeometricType)

set the attribute _geometricType to geometricType

References _entity, _geometricType, _name, _numberOfGeometricType, and _profilNames.

Referenced by getBoundaryElements(), MEDMEM::MESH::getSkin(), setEntity(), and update().

void SUPPORT::setNumberOfElements ( const int *  NumberOfElements)

Set the attribute _numberOfElements to NumberOfElements and calculate the total number of elements.

References _numberOfElements, _numberOfGeometricType, and _totalNumberOfElements.

Referenced by getBoundaryElements(), and MEDMEM::MESH::getSkin().

void SUPPORT::setNumber ( MEDSKYLINEARRAY *  Number)

set the attribute _number to Number

References _number.

Referenced by MEDMEM::MESH::getSkin(), and update().

void SUPPORT::setNumber ( const int *  index,
const int *  value,
bool  shallowCopy = false 
)

set the attribute _number with index and value arrays

References _number, and _totalNumberOfElements.

const std::string & MEDMEM::SUPPORT::getName ( ) const

returns the name of the support.

Referenced by buildSupportOnNode(), makeMesh(), and ParaMEDMEM::medmemSupportToFVMMesh().

const std::string & MEDMEM::SUPPORT::getDescription ( ) const

returns the description of the support.

const GMESH * MEDMEM::SUPPORT::getMesh ( ) const
virtual
string SUPPORT::getMeshName ( ) const

returns the mesh name

References _mesh, _meshName, and MEDMEM::GMESH::getName().

MED_EN::medEntityMesh MEDMEM::SUPPORT::getEntity ( ) const

Returns the medEntityMesh's type used by the support. Note : A support deals only with one entity's type (for example : MED_FACE or MED_NODE)

Referenced by buildSupportOnNode(), and ParaMEDMEM::medmemSupportToFVMMesh().

bool MEDMEM::SUPPORT::isOnAllElements ( ) const

Returns true if all elements of this entity are concerned, false otherwise. If true, you must use mesh reference (getMesh) to get more information.

Referenced by buildSupportOnNode(), and ParaMEDMEM::medmemSupportToFVMMesh().

int MEDMEM::SUPPORT::getNumberOfTypes ( ) const

Returns number of geometric Types defines in the support

Referenced by ParaMEDMEM::medmemSupportToFVMMesh().

const MED_EN::medGeometryElement * MEDMEM::SUPPORT::getTypes ( ) const

If isOnAllElements is false, returns an array of medGeometryElement types used by the support.

Referenced by makeMesh(), and ParaMEDMEM::medmemSupportToFVMMesh().

MEDSKYLINEARRAY * SUPPORT::getnumber ( ) const throw (MEDEXCEPTION)
virtual

References _number.

MEDSKYLINEARRAY * SUPPORT::getnumberFromFile ( ) const throw (MEDEXCEPTION)
virtual

References _number_fromfile.

const int * SUPPORT::getNumber ( MED_EN::medGeometryElement  GeometricType) const throw (MEDEXCEPTION)
virtual

Returns an array which contains all number of given medGeometryElement.

Numbering is global, ie numbers are bounded by 1 and GMESH::getNumberOfElement(entity,MED_ALL_ELEMENTS) and not by 1 and GMESH::getNumberOfElement(entity,geomElement).

Note : If SUPPORT is defined on MED_NODE, use MED_NONE medGeometryElement type.

Referenced by deepCompare(), makeMesh(), and ParaMEDMEM::medmemSupportToFVMMesh().

const int * SUPPORT::getNumberFromFile ( MED_EN::medGeometryElement  GeometricType) const throw (MEDEXCEPTION)
virtual
int SUPPORT::getValIndFromGlobalNumber ( const int  number) const throw (MEDEXCEPTION)
virtual

Get the field value index (in fortran mode) from the support global number. Becareful, it doesn't take care of the field number of components

void MEDMEM::SUPPORT::setpartial ( const std::string &  Description,
int  NumberOfGeometricType,
int  TotalNumberOfEntity,
const MED_EN::medGeometryElement *  GeometricType,
const int *  NumberOfEntity,
const int *  NumberValue 
)
void SUPPORT::setpartial ( MEDSKYLINEARRAY *  number,
bool  shallowCopy = false 
) throw (MEDEXCEPTION)
void SUPPORT::setpartial_fromfile ( MEDSKYLINEARRAY *  number,
bool  shallowCopy = false 
) throw (MEDEXCEPTION)
void SUPPORT::setProfilNames ( const std::vector< std::string > &  profilNames) throw (MEDEXCEPTION)
vector< string > SUPPORT::getProfilNames ( ) const throw (MEDEXCEPTION)

References _profilNames.

void SUPPORT::changeElementsNbs ( MED_EN::medEntityMesh  entity,
const int *  renumberingFromOldToNew 
)
bool MEDMEM::SUPPORT::belongsTo ( const SUPPORT other,
bool  deepCompare = false 
) const

States if this is included in other.

References _entity, _geometricType, _isOnAllElts, _mesh, _number, _numberOfElements, and _numberOfGeometricType.

SUPPORT * MEDMEM::SUPPORT::getComplement ( ) const

returns a new SUPPORT (responsability to caller to destroy it) that is the complement to "this", lying on the same entity than "this".

References getNumberOfElements(), setEntity(), setMesh(), and setName().

Referenced by substract().

SUPPORT * MEDMEM::SUPPORT::substract ( const SUPPORT other) const throw (MEDEXCEPTION)

returns a new support the user should delete.

References getComplement(), setEntity(), and setMesh().

SUPPORT* MEDMEM::SUPPORT::getBoundaryElements ( MED_EN::medEntityMesh  Entity) const throw (MEDEXCEPTION)
SUPPORT * SUPPORT::buildSupportOnNode ( ) const throw (MEDEXCEPTION)
void MEDMEM::SUPPORT::fillFromNodeList ( const std::list< int > &  listOfNode) throw (MEDEXCEPTION)

Method that fills this and updates all its attributes in order to lye on the the listOfNode.

void MEDMEM::SUPPORT::fillFromElementList ( const std::list< int > &  listOfElt) throw (MEDEXCEPTION)
void MEDMEM::SUPPORT::clearDataOnNumbers ( )

Method that cleans up all the fields related to _numbers. Defined for code factorization.

Referenced by ~SUPPORT().

MESH * SUPPORT::makeMesh ( ) const
list< int > * MEDMEM::SUPPORT::sub ( int  start,
int  end,
const int *  idsToSuppress,
int  lgthIdsToSuppress 
)
staticprotected

performs a common operation : Sub builds a sorted int array that is obtained by supression of all ids contained in array defined by (idsToSuppress,lgthIdsToSuppress) from array [start ... end] Example sub(0,7,{1,2,5},3) => {0,3,4,6,7} - WARNING returned list should be deallocated !

References compareId().

list< int > * MEDMEM::SUPPORT::sub ( const int *  ids,
int  lgthIds,
const int *  idsToSuppress,
int  lgthIdsToSuppress 
)
staticprotected

performs a common operation : Sub builds a sorted int array that is obtained by supression of all ids contained in array defined by (idsToSuppress,lgthIdsToSuppress) from array [start ... end] Example sub({1,3,4,5,6,7,9},7,{1,2,5},3) => {3,4,6,7,9} - WARNING returned list should be deallocated !

References compareId().

Friends And Related Function Documentation

MEDMEM_EXPORT ostream& operator<< ( ostream &  os,
const SUPPORT my 
)
friend

Member Data Documentation

std::string MEDMEM::SUPPORT::_name
protected
std::string MEDMEM::SUPPORT::_meshName
mutableprotected

Referenced by getMeshName(), setMeshName(), and SUPPORT().

std::string MEDMEM::SUPPORT::_description
protected

Referenced by operator=(), and SUPPORT().

const GMESH* MEDMEM::SUPPORT::_mesh
mutableprotected
MED_EN::medEntityMesh MEDMEM::SUPPORT::_entity
protected
int MEDMEM::SUPPORT::_numberOfGeometricType
protected
PointerOf<MED_EN::medGeometryElement> MEDMEM::SUPPORT::_geometricType
protected
bool MEDMEM::SUPPORT::_isOnAllElts
protected
PointerOf<int> MEDMEM::SUPPORT::_numberOfElements
protected
int MEDMEM::SUPPORT::_totalNumberOfElements
protected
MEDSKYLINEARRAY* MEDMEM::SUPPORT::_number
mutableprotected
MEDSKYLINEARRAY* MEDMEM::SUPPORT::_number_fromfile
mutableprotected

Referenced by getnumberFromFile().

std::vector< std::string > MEDMEM::SUPPORT::_profilNames
protected
Copyright © 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE
Copyright © 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS