matrt Class Reference

#include <dbmatt.h>

List of all members.

Public Member Functions

void alloc (long ni)
 allocates memory for material paramaters stored as strings
void alloctm (long ni)
 allocates memory for material paramaters read/stored by transmat procedures
 matrt (void)
long read (XFILE *in)
 reads material parameters from the opened text file as strings
 ~matrt (void)

Public Attributes

char ** inst
 array of strings with material properties (material indeces)
long * instu
 array indicators of indeces which are used
long ninst
 number of indeces
long ninstu
 counter used indeces this material type
long * ridx
 array with renumbered used indeces
mattypet type
 material type number

Detailed Description

Material class

Created by Tomas Koudelka, koudelka@cml.fsv.cvut.cz Modified 04.2008 by Tomas Koudelka, koudelka@cml.fsv.cvut.cz

Definition at line 16 of file dbmatt.h.


Constructor & Destructor Documentation

matrt ( void   ) 

Constructor which initializes data members with null or zero values.

Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 11. 2001

Definition at line 15 of file dbmatt.cpp.

References inst, instu, ninst, ninstu, ridx, and type.

~matrt ( void   ) 

Destructor which deletes each string with material properties.

Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 11. 2001

Definition at line 32 of file dbmatt.cpp.

References inst, instu, ninst, and ridx.


Member Function Documentation

void alloc ( long  ni  ) 

allocates memory for material paramaters stored as strings

The function allocates memory for ni sets of material parameters that will be read as strings.

Parameters:
ni - number of allocated instances
Returns:
The function does not return anything.

Created by Tomas Koudelka, 30.6.2014

Definition at line 57 of file dbmatt.cpp.

References inst, instu, memset(), ninst, and ridx.

Referenced by read().

void alloctm ( long  ni  ) 

allocates memory for material paramaters read/stored by transmat procedures

The function allocates memory for ni sets of material parameters that will be read/stored via transmat procedures.

Parameters:
ni - number of allocated instances
Returns:
The function does not return anything.

Created by Tomas Koudelka, 30.6.2014

Definition at line 80 of file dbmatt.cpp.

References instu, memset(), ninst, and ridx.

Referenced by dbmatt::readtm().

long read ( XFILE in  ) 

reads material parameters from the opened text file as strings

This method reads one type of material with different parameters from the opened text file in.

Parameters:
in - opened text file with material data.

Returns:

Return values:
0 - on succes
1 - error reading index of material type instance

Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 7. 2009

Definition at line 102 of file dbmatt.cpp.

References alloc(), XFILE::col, XFILE::fname, inst, XFILE::line, mattypet_kwdset(), memset(), ninst, print_err(), skipline(), type, and xfscanf().


Member Data Documentation

char** inst

array of strings with material properties (material indeces)

Definition at line 21 of file dbmatt.h.

Referenced by alloc(), matrt(), read(), wr_materialst(), and ~matrt().

long* instu

array indicators of indeces which are used

Definition at line 22 of file dbmatt.h.

Referenced by alloc(), alloctm(), dbmatt::mark_used(), matrt(), wr_materialst(), and ~matrt().

long ninst

number of indeces

Definition at line 20 of file dbmatt.h.

Referenced by alloc(), alloctm(), matrt(), read(), dbmatt::readtm(), dbmatt::renumber_id(), wr_materialst(), and ~matrt().

long ninstu

counter used indeces this material type

Definition at line 24 of file dbmatt.h.

Referenced by dbmatt::mark_used(), matrt(), and wr_materialst().

long* ridx

array with renumbered used indeces

Definition at line 23 of file dbmatt.h.

Referenced by alloc(), alloctm(), matrt(), dbmatt::renumber_id(), wr_elementst(), wr_materialst(), and ~matrt().

material type number

Definition at line 19 of file dbmatt.h.

Referenced by matrt(), read(), dbmatt::readtm(), and wr_materialst().


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

Generated by  doxygen 1.6.2