Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
xDataTOM_W_XYs_LegendreSeries.cc File Reference
#include <string.h>
#include "xDataTOM_private.h"

Go to the source code of this file.

Functions

int xDataTOM_W_XYs_LegendreSeries_initialize (statusMessageReporting *smr, xDataTOM_W_XYs_LegendreSeries *W_XYs_LegendreSeries, int index, int length, double value, enum xDataTOM_subAxesType subAxesType, xDataTOM_axes *axes, xDataTOM_interpolation *interpolation)
 
int xDataTOM_W_XYs_LegendreSeries_free (xDataTOM_xDataInfo *xDI)
 
int xDataTOM_W_XYs_LegendreSeries_release (xDataTOM_W_XYs_LegendreSeries *W_XYs_LegendreSeries)
 

Variables

char const * xDataTOM_W_XYs_LegendreSeries_ID = "W_XYs_LegendreSeries"
 

Function Documentation

◆ xDataTOM_W_XYs_LegendreSeries_free()

int xDataTOM_W_XYs_LegendreSeries_free ( xDataTOM_xDataInfo xDI)

Definition at line 34 of file xDataTOM_W_XYs_LegendreSeries.cc.

34 {
35
36 if( xDI == NULL ) return( 0 );
37 if( strcmp( xDataTOM_W_XYs_LegendreSeries_ID, xDI->ID ) != 0 ) return( 1 );
39 smr_freeMemory( (void **) &(xDI->data) );
40 return( 0 );
41}
void * smr_freeMemory(void **p)
const char * ID
Definition: xDataTOM.h:151
int xDataTOM_W_XYs_LegendreSeries_release(xDataTOM_W_XYs_LegendreSeries *W_XYs_LegendreSeries)
char const * xDataTOM_W_XYs_LegendreSeries_ID

Referenced by xDataTOM_releaseElement().

◆ xDataTOM_W_XYs_LegendreSeries_initialize()

int xDataTOM_W_XYs_LegendreSeries_initialize ( statusMessageReporting smr,
xDataTOM_W_XYs_LegendreSeries W_XYs_LegendreSeries,
int  index,
int  length,
double  value,
enum xDataTOM_subAxesType  subAxesType,
xDataTOM_axes axes,
xDataTOM_interpolation interpolation 
)

Definition at line 19 of file xDataTOM_W_XYs_LegendreSeries.cc.

20 {
21
22 W_XYs_LegendreSeries->LegendreSeries = NULL;
23 W_XYs_LegendreSeries->index = index;
24 W_XYs_LegendreSeries->length = length;
25 W_XYs_LegendreSeries->value = value;
26 if( xDataTOM_subAxes_initialize( smr, &(W_XYs_LegendreSeries->subAxes), subAxesType, 0, axes, interpolation ) != 0 ) return( 1 );
27 if( ( W_XYs_LegendreSeries->LegendreSeries = (xDataTOM_LegendreSeries *) smr_malloc2( smr, length * sizeof( xDataTOM_LegendreSeries ), 1, "W_XYs_LegendreSeries->LegendreSeries" ) ) == NULL ) return( 1 );
28
29 return( 0 );
30}
#define smr_malloc2(smr, size, zero, forItem)
xDataTOM_LegendreSeries * LegendreSeries
Definition: xDataTOM.h:116
xDataTOM_subAxes subAxes
Definition: xDataTOM.h:115
int xDataTOM_subAxes_initialize(statusMessageReporting *smr, xDataTOM_subAxes *subAxes, enum xDataTOM_subAxesType type, int offset, xDataTOM_axes *axes, xDataTOM_interpolation *interpolation)

Referenced by xDataXML_W_XYs_LegendreSeriesToTOM().

◆ xDataTOM_W_XYs_LegendreSeries_release()

int xDataTOM_W_XYs_LegendreSeries_release ( xDataTOM_W_XYs_LegendreSeries W_XYs_LegendreSeries)

Definition at line 45 of file xDataTOM_W_XYs_LegendreSeries.cc.

45 {
46
47 int i;
48
49 for( i = 0; i < W_XYs_LegendreSeries->length; i++ ) xDataTOM_LegendreSeries_release( &(W_XYs_LegendreSeries->LegendreSeries[i]) );
50 smr_freeMemory( (void **) &(W_XYs_LegendreSeries->LegendreSeries) );
51 return( 0 );
52}
int xDataTOM_LegendreSeries_release(xDataTOM_LegendreSeries *LegendreSeries)

Referenced by xDataTOM_regionsW_XYs_LegendreSeries_release(), xDataTOM_V_W_XYs_LegendreSeries_free(), and xDataTOM_W_XYs_LegendreSeries_free().

Variable Documentation

◆ xDataTOM_W_XYs_LegendreSeries_ID

char const* xDataTOM_W_XYs_LegendreSeries_ID = "W_XYs_LegendreSeries"