TCNOpen TRDP-SPY  2.0
trdpDict.c File Reference

Parser of the XML description. More...

#include "trdpDict.h"
#include <errno.h>
#include <stdio.h>
Include dependency graph for trdpDict.c:

Functions

static gint32 ComId_preCalculate (ComId *self, const TrdpDict *dict)
 
static gint32 Dataset_preCalculate (Dataset *self, const TrdpDict *dict)
 calculateSize More...
 
gchar * TrdpDict_summary (const TrdpDict *self)
 Get some human-readable info. More...
 
const ComIdTrdpDict_lookup_ComId (const TrdpDict *self, guint32 comId)
 Lookup a given comId in the dictionary self. More...
 
DatasetTrdpDict_get_Dataset (const TrdpDict *self, guint32 datasetId)
 Lookup a given datasetId in the dictionary self. More...
 

Detailed Description

Parser of the XML description.

(was trdpConfigHandler.cpp)

Note
Project: TRDP SPY
Author
Florian Weispfenning, Bombardier Transportation
Thorsten Schulz, Universität Rostock
Id

Function Documentation

◆ ComId_preCalculate()

static gint32 ComId_preCalculate ( ComId self,
const TrdpDict dict 
)
static

< must only be called after full config initialization

Here is the call graph for this function:

◆ Dataset_preCalculate()

static gint32 Dataset_preCalculate ( Dataset self,
const TrdpDict dict 
)
static

calculateSize

Calculate the size of the elements and its contents

Returns
size (==getSize()), or -1 on error, 0 on variable elements
Here is the caller graph for this function:

◆ TrdpDict_get_Dataset()

Dataset * TrdpDict_get_Dataset ( const TrdpDict self,
guint32  datasetId 
)

Lookup a given datasetId in the dictionary self.

You may read and change information on the returned item, but do not free it

Parameters
selfTrdpDict instance
datasetIdThe number referencing the Dataset item
Returns
pointer to the Dataset item in the dictionary or NULL if not found
Here is the caller graph for this function:

◆ TrdpDict_lookup_ComId()

const ComId * TrdpDict_lookup_ComId ( const TrdpDict self,
guint32  comId 
)

Lookup a given comId in the dictionary self.

You may only read on the returned item.

Parameters
selfTrdpDict instance
comIdThe number referencing the ComId item
Returns
pointer to the ComId item in the dictionary or NULL if not found

◆ TrdpDict_summary()

gchar * TrdpDict_summary ( const TrdpDict self)

Get some human-readable info.

The caller is responsible to free the returned string.

Parameters
selfTrdpDict instance
Returns
info string to be freed be caller