Go to the source code of this file.
 | 
| #define  | MCGIDI_misc_pointerToTOMAttributeIfAllOk2(smr,  required,  attributes,  name)   MCGIDI_misc_pointerToTOMAttributeIfAllOk( smr, NULL, required, attributes, name, __FILE__, __LINE__ ) | 
|   | 
| #define  | MCGIDI_misc_pointerToTOMAttributeIfAllOk3(smr,  path,  required,  attributes,  name)   MCGIDI_misc_pointerToTOMAttributeIfAllOk( smr, path, required, attributes, name, __FILE__, __LINE__ ) | 
|   | 
| #define  | MCGIDI_misc_pointerToAttributeIfAllOk2(smr,  element,  required,  attributes,  name)   MCGIDI_misc_pointerToAttributeIfAllOk( smr, element, NULL, required, attributes, name, __FILE__, __LINE__ ) | 
|   | 
| #define  | MCGIDI_misc_pointerToAttributeIfAllOk3(smr,  path,  required,  attributes,  name)   MCGIDI_misc_pointerToAttributeIfAllOk( smr, NULL, path, required, attributes, name, __FILE__, __LINE__ ) | 
|   | 
 | 
| char const  *  | MCGIDI_misc_pointerToTOMAttributeIfAllOk (statusMessageReporting *smr, char const *path, int required, xDataTOM_attributionList *attributes, char const *name, char const *file, int line) | 
|   | 
| char const  *  | MCGIDI_misc_pointerToAttributeIfAllOk (statusMessageReporting *smr, xDataXML_element *element, char const *path, int required, xDataTOM_attributionList *attributes, char const *name, char const *file, int line) | 
|   | 
| int  | MCGIDI_misc_setMessageError_Element (statusMessageReporting *smr, void *userInterface, xDataXML_element *element, char const *file, int line, int code, char const *fmt,...) | 
|   | 
| char *  | MCGIDI_misc_getAbsPath (statusMessageReporting *smr, char const *fileName) | 
|   | 
| int  | MCGIDI_misc_copyXMLAttributesToTOM (statusMessageReporting *smr, xDataTOM_attributionList *TOM, xDataXML_attributionList *XML) | 
|   | 
| enum xDataTOM_frame  | MCGIDI_misc_getProductFrame (statusMessageReporting *smr, xDataTOM_element *frameElement) | 
|   | 
| double  | MCGIDI_misc_getUnitConversionFactor (statusMessageReporting *smr, char const *fromUnit, char const *toUnit) | 
|   | 
| ptwXYPoints *  | MCGIDI_misc_dataFromXYs2ptwXYPointsInUnitsOf (statusMessageReporting *smr, xDataTOM_XYs *XYs, ptwXY_interpolation interpolation, char const *units[2]) | 
|   | 
| ptwXYPoints *  | MCGIDI_misc_dataFromElement2ptwXYPointsInUnitsOf (statusMessageReporting *smr, xDataTOM_element *linear, char const *toUnits[2]) | 
|   | 
◆ MCGIDI_misc_pointerToAttributeIfAllOk2
      
        
          | #define MCGIDI_misc_pointerToAttributeIfAllOk2 | 
          ( | 
            | 
          smr,  | 
        
        
           | 
           | 
            | 
          element,  | 
        
        
           | 
           | 
            | 
          required,  | 
        
        
           | 
           | 
            | 
          attributes,  | 
        
        
           | 
           | 
            | 
          name  | 
        
        
           | 
          ) | 
           |    MCGIDI_misc_pointerToAttributeIfAllOk( smr, element, NULL, required, attributes, name, __FILE__, __LINE__ ) | 
        
      
 
 
◆ MCGIDI_misc_pointerToAttributeIfAllOk3
      
        
          | #define MCGIDI_misc_pointerToAttributeIfAllOk3 | 
          ( | 
            | 
          smr,  | 
        
        
           | 
           | 
            | 
          path,  | 
        
        
           | 
           | 
            | 
          required,  | 
        
        
           | 
           | 
            | 
          attributes,  | 
        
        
           | 
           | 
            | 
          name  | 
        
        
           | 
          ) | 
           |    MCGIDI_misc_pointerToAttributeIfAllOk( smr, NULL, path, required, attributes, name, __FILE__, __LINE__ ) | 
        
      
 
 
◆ MCGIDI_misc_pointerToTOMAttributeIfAllOk2
◆ MCGIDI_misc_pointerToTOMAttributeIfAllOk3
      
        
          | #define MCGIDI_misc_pointerToTOMAttributeIfAllOk3 | 
          ( | 
            | 
          smr,  | 
        
        
           | 
           | 
            | 
          path,  | 
        
        
           | 
           | 
            | 
          required,  | 
        
        
           | 
           | 
            | 
          attributes,  | 
        
        
           | 
           | 
            | 
          name  | 
        
        
           | 
          ) | 
           |    MCGIDI_misc_pointerToTOMAttributeIfAllOk( smr, path, required, attributes, name, __FILE__, __LINE__ ) | 
        
      
 
 
◆ MCGIDI_misc_copyXMLAttributesToTOM()
Definition at line 296 of file MCGIDI_misc.cc.
  302     for( i = 0; ; i++ ) {
 
void xDataTOMAL_initial(statusMessageReporting *smr, xDataTOM_attributionList *attributes)
 
void xDataTOMAL_release(xDataTOM_attributionList *attributes)
 
xDataXML_attribute * xDataXML_attributeByIndex(xDataXML_attributionList *attributes, int index)
 
int xDataTOMAL_addAttribute(statusMessageReporting *smr, xDataTOM_attributionList *attributes, char const *name, char const *value)
 
 
 
 
◆ MCGIDI_misc_dataFromElement2ptwXYPointsInUnitsOf()
Definition at line 424 of file MCGIDI_misc.cc.
  429     char const *fromUnits[2];
 
int MCGIDI_fromTOM_interpolation(statusMessageReporting *smr, xDataTOM_element *element, int index, enum ptwXY_interpolation_e *interpolation)
 
int xDataTOM_XYs_getDataFromXDataInfo(xDataTOM_xDataInfo *xDI, double **data)
 
#define smr_setReportError2(smr, libraryID, code, fmt,...)
 
enum ptwXY_interpolation_e ptwXY_interpolation
 
xDataTOM_xDataInfo xDataInfo
 
static ptwXYPoints * MCGIDI_misc_Data2ptwXYPointsInUnitsOf(statusMessageReporting *smr, ptwXY_interpolation interpolation, int length, double *data, char const *fromUnits[2], char const *toUnits[2])
 
 
 
 
◆ MCGIDI_misc_dataFromXYs2ptwXYPointsInUnitsOf()
Definition at line 405 of file MCGIDI_misc.cc.
  410     char const *fromUnits[2];
   413     if( !
smr_isOk( smr ) ) 
return( NULL );
   415     if( !
smr_isOk( smr ) ) 
return( NULL );
 
int smr_isOk(statusMessageReporting *smr)
 
static ptwXYPoints * MCGIDI_misc_Data2ptwXYPointsInUnitsOf(statusMessageReporting *smr, ptwXY_interpolation interpolation, int length, double *data, char const *fromUnits[2], char const *toUnits[2])
 
int xDataTOM_XYs_getData(xDataTOM_XYs *XYs, double **data)
 
char const  * xDataTOM_subAxes_getUnit(statusMessageReporting *smr, xDataTOM_subAxes *subAxes, int index)
 
 
 
 
◆ MCGIDI_misc_getAbsPath()
Definition at line 250 of file MCGIDI_misc.cc.
  254     int n = (int) strlen( fileName ) + 1, nCwd = 0;
   255     char *absPath, cwd[4 * 1024] = 
"", *p, *needle;
   257     if( fileName[0] != 
'/' ) {
   260         if( getcwd( cwd, 
sizeof( cwd ) ) == NULL ) {
   264         nCwd = (int) strlen( cwd );
   267     if( ( absPath = (
char *) 
smr_malloc2( smr, n, 0, 
"absPath" ) ) == NULL ) 
return( NULL );
   268     if( fileName[0] != 
'/' ) {
   269         strcpy( absPath, cwd );
   270         strcat( absPath, 
"/" );
   271         strcat( absPath, fileName ); }
   273         strcpy( absPath, fileName );
   277         if( ( needle = strstr( absPath, 
"/./" ) ) == NULL ) 
break;
   279         for( needle += 2; *needle; p++, needle++ ) *p = *needle;
   283         if( ( needle = strstr( absPath, 
"/../" ) ) == NULL ) 
break;
   285         while( ( p > absPath ) && ( *p != 
'/' ) ) p--; 
   286         if( *p != 
'/' ) 
break;                           
   287         if( p == absPath ) 
break;                       
   288         for( needle += 3; *needle; p++, needle++ ) *p = *needle;
 
#define smr_setReportError2p(smr, libraryID, code, fmt)
 
#define smr_malloc2(smr, size, zero, forItem)
 
 
 
 
◆ MCGIDI_misc_getProductFrame()
Definition at line 315 of file MCGIDI_misc.cc.
  317     char const *frameString;
 enum xDataTOM_frame xDataTOM_axis_stringToFrame(statusMessageReporting *smr, char const *frame)
 
#define smr_setReportError2(smr, libraryID, code, fmt,...)
 
#define MCGIDI_token_productFrame
 
char const  * xDataTOM_getAttributesValueInElement(xDataTOM_element *element, char const *name)
 
 
 
 
◆ MCGIDI_misc_getUnitConversionFactor()
      
        
          | double MCGIDI_misc_getUnitConversionFactor  | 
          ( | 
          statusMessageReporting *  | 
          smr,  | 
        
        
           | 
           | 
          char const *  | 
          fromUnit,  | 
        
        
           | 
           | 
          char const *  | 
          toUnit  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Definition at line 381 of file MCGIDI_misc.cc.
  385     if( strcmp( fromUnit, toUnit ) == 0 ) 
return( 1.0 );
   387     if( strcmp( fromUnit, 
"eV" ) == 0 ) {
   388         if( strcmp( toUnit, 
"MeV" ) == 0 ) 
return( 1
e-6 ); }
   389     else if( strcmp( fromUnit, 
"MeV" ) == 0 ) {
   390         if( strcmp( toUnit, 
"eV" ) == 0 ) 
return( 1
e+6 ); }
   391     else if( strcmp( fromUnit, 
"1/eV" ) == 0 ) {
   392         if( strcmp( toUnit, 
"1/MeV" ) == 0 ) 
return( 1
e+6 ); }
   393     else if( strcmp( fromUnit, 
"1/MeV" ) == 0 ) {
   394         if( strcmp( toUnit, 
"1/eV" ) == 0 ) 
return( 1
e-6 ); }
   395     else if( strcmp( fromUnit, 
"K" ) == 0 ) {
   396         if( strcmp( toUnit, 
"MeV/k" ) == 0 ) 
return( 8.617343183775137
e-11 );
 #define smr_setReportError2(smr, libraryID, code, fmt,...)
 
 
 
 
◆ MCGIDI_misc_pointerToAttributeIfAllOk()
Definition at line 184 of file MCGIDI_misc.cc.
  189     if( !
smr_isOk( smr ) ) 
return( NULL );
   192             if( element != NULL ) {
 
char const  * xDataTOMAL_getAttributesValue(xDataTOM_attributionList *attributes, char const *name)
 
int MCGIDI_misc_setMessageError_Element(statusMessageReporting *smr, void *userInterface, xDataXML_element *element, const char *file, int line, int code, const char *fmt,...)
 
int smr_isOk(statusMessageReporting *smr)
 
int smr_setReportError(statusMessageReporting *smr, void *userInterface, char const *file, int line, char const *function, int libraryID, int code, char const *fmt,...)
 
 
 
 
◆ MCGIDI_misc_pointerToTOMAttributeIfAllOk()
Definition at line 168 of file MCGIDI_misc.cc.
  173     if( !
smr_isOk( smr ) ) 
return( NULL );
 
char const  * xDataTOMAL_getAttributesValue(xDataTOM_attributionList *attributes, char const *name)
 
int smr_isOk(statusMessageReporting *smr)
 
int smr_setReportError(statusMessageReporting *smr, void *userInterface, char const *file, int line, char const *function, int libraryID, int code, char const *fmt,...)
 
 
 
 
◆ MCGIDI_misc_setMessageError_Element()
Definition at line 204 of file MCGIDI_misc.cc.
  211     va_start( args, fmt );
   216         va_start( args, fmt );
 
int smr_vsetReportError(statusMessageReporting *smr, void *userInterface, char const *file, int line, char const *function, int libraryID, int code, char const *fmt, va_list *args)
 
void * smr_freeMemory(void **p)
 
char * smr_vallocateFormatMessage(char const *fmt, va_list *args)
 
int smr_setReportError(statusMessageReporting *smr, void *userInterface, char const *file, int line, char const *function, int libraryID, int code, char const *fmt,...)