Pointwise Plugin SDK
Functions | Variables
apiCAEPUtils.cxx File Reference
#include <algorithm>
#include <string>
#include <vector>
#include <string.h>
#include "apiPWP.h"
#include "apiCAEPUtils.h"
#include "apiGridModel.h"
#include "pwpPlatform.h"
+ Include dependency graph for apiCAEPUtils.cxx:

Go to the source code of this file.

Functions

PWP_BOOL caeuAssignInfoValue (const char key[], const char value[], bool createIfNotExists)
 Creates a key/value pair that defines a CAE info attribute. More...
 
const char * caeuDimensionToText (PWP_ENUM_DIMENSION dim)
 Converts a PWP_ENUM_DIMENSION value to a text string representation. More...
 
const char * caeuEncodeToText (PWP_ENUM_ENCODING enc)
 Converts a PWP_ENUM_ENCODING value to a text string representation. More...
 
PWP_BOOL caeuExportBndryConditionsOnly (PWGM_HGRIDMODEL model)
 Get the user-requested bc export option. More...
 
PWP_BOOL caeuExportStructuredAsUnstructured (PWGM_HGRIDMODEL model)
 Get the user-requested structured grid handling. More...
 
PWP_ENDIANNESS caeuFileByteOrder (PWGM_HGRIDMODEL model)
 Get the user-requested file byte order. More...
 
int caeuFileClose (CAEP_RTITEM *pRti, const CAEP_WRITEINFO *pWriteInfo)
 Closes pRti for file I/O as specified by pWriteInfo. More...
 
PWP_ENUM_ENCODING caeuFileEncoding (PWGM_HGRIDMODEL model)
 Get the user-requested file encoding. More...
 
int caeuFileOpen (CAEP_RTITEM *pRti, const CAEP_WRITEINFO *pWriteInfo)
 Prepare pRti for file I/O as specified by pWriteInfo. More...
 
PWP_ENUM_PRECISION caeuFilePrecision (PWGM_HGRIDMODEL model)
 Get the user-requested file precision. More...
 
CAEP_RTITEMcaeuFindFormatById (PWP_UINT32 id)
 Find an item in caepRtItem[] by it's id. More...
 
CAEP_RTITEMcaeuFindFormatByName (const char name[])
 Find an item in caepRtItem[] by it's name. More...
 
const char * caeuPrecisionToText (PWP_ENUM_PRECISION prec)
 Converts a PWP_ENUM_PRECISION value to a text string representation. More...
 
PWP_BOOL caeuProgressBeginStep (CAEP_RTITEM *pRti, PWP_UINT32 total)
 Begins a progress tracking step. More...
 
void caeuProgressEnd (CAEP_RTITEM *pRti, PWP_BOOL ok)
 Ends all progress tracking. More...
 
PWP_BOOL caeuProgressEndStep (CAEP_RTITEM *pRti)
 Completes a progress tracking major step. More...
 
PWP_BOOL caeuProgressIncr (CAEP_RTITEM *pRti)
 Completes a progress tracking sub-step. More...
 
PWP_BOOL caeuProgressInit (CAEP_RTITEM *pRti, PWP_UINT32 cnt)
 Initializes a progress tracking session. More...
 
PWP_BOOL caeuPublishHighOrderValueDefinitions (const PWP_UINT32 maxPolynomialDegree)
 Enables support for the export of high order meshes and publishes all needed value definitions. More...
 
PWP_BOOL caeuPublishMeshLinkValueDefinitions (const char *indexScheme)
 Enables support for the export of MeshLink data and publishes all needed value definitions. More...
 
PWP_BOOL caeuPublishValueDefinition (const char key[], PWP_ENUM_VALTYPE type, const char value[], const char access[], const char desc[], const char range[])
 Creates a collection of key/value pairs that represent a published CAE attribute definition. More...
 
void caeuSendDebugMsg (CAEP_RTITEM *pRti, const char txt[], PWP_UINT32 code)
 Send a debug text message (PWP_MSGID_DEBUG) to the framework. More...
 
void caeuSendErrorMsg (CAEP_RTITEM *pRti, const char txt[], PWP_UINT32 code)
 Send an error text message (PWP_MSGID_ERROR) to the framework. More...
 
void caeuSendInfoMsg (CAEP_RTITEM *pRti, const char txt[], PWP_UINT32 code)
 Send an info text message (PWP_MSGID_INFO) to the framework. More...
 
void caeuSendWarningMsg (CAEP_RTITEM *pRti, const char txt[], PWP_UINT32 code)
 Send a warning text message (PWP_MSGID_WARNING) to the framework. More...
 
static int fileDestCwdPush (const char *fileDest)
 
static int openFileName (CAEP_RTITEM *pRti, const CAEP_WRITEINFO *pWriteInfo)
 
static void sendClkDiffTimeMsg (CAEP_RTITEM *pRti, const char txt[], CAEPU_ENUM_CLOCKS startId, CAEPU_ENUM_CLOCKS endId)
 
static void sendDiffTimeMsg (CAEP_RTITEM *pRti, const char txt[], clock_t diff)
 

Variables

static const char * invalid = "!invalid"
 

Function Documentation

◆ fileDestCwdPush()

static int fileDestCwdPush ( const char *  fileDest)
static

Definition at line 417 of file apiCAEPUtils.cxx.

References FILENAME_MAX, and pwpCwdPush().

Referenced by caeuFileOpen().

◆ openFileName()

static int openFileName ( CAEP_RTITEM pRti,
const CAEP_WRITEINFO pWriteInfo 
)
static

◆ sendClkDiffTimeMsg()

static void sendClkDiffTimeMsg ( CAEP_RTITEM pRti,
const char  txt[],
CAEPU_ENUM_CLOCKS  startId,
CAEPU_ENUM_CLOCKS  endId 
)
static

Definition at line 136 of file apiCAEPUtils.cxx.

References CAEPU_RT_CLKS_DIFF, and sendDiffTimeMsg().

Referenced by caeuProgressEnd(), and caeuProgressEndStep().

◆ sendDiffTimeMsg()

static void sendDiffTimeMsg ( CAEP_RTITEM pRti,
const char  txt[],
clock_t  diff 
)
static

Definition at line 114 of file apiCAEPUtils.cxx.

References CAEPU_CLKS_TO_HMS, CAEPU_CLKS_TO_MSECS, and caeuSendDebugMsg().

Referenced by sendClkDiffTimeMsg().

Variable Documentation

◆ invalid

const char* invalid = "!invalid"
static

Definition at line 482 of file apiCAEPUtils.cxx.

Referenced by caeuDimensionToText(), caeuEncodeToText(), and caeuPrecisionToText().