libdas2
das2 core C utilities
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions
DasAry Struct Reference

#include <das2/array.h>

Detailed Description

Dynamic recursive ragged arrays.

This class maps any number of indices, (i,j,k...) to elements stored into a continuous array. Any or all particular index in the array can be ragged, if desired, though typically for data streams only the first index has an arbitrary length.

The backing buffers for the array grows if needed as new elements are appended. Individual elements may be arbitrary composite types, though extra capabilites are provided for a handful of know types.

*
* // For this example, assume the file below consists of big endian floats
* const char* my_file = "my_big_endian_datafile.dat";
* FILE* in_file = fopen(my_file, "rb");
*
* // The following Rank 2 array is initially 0 records long and has
* // 152 values per record. Thus it starts as a 0 by 152 array
* Array* pAry = new_Array("amplitudes", etFloat, 0, NULL, RANK_2(0, 152));
*
* // Set byte order for input values. This will trigger swapping if host
* // byte order is different from input order. Note that this only works
* // for the types in the element_type enumeration. For unknown types you'll
* // have to do your own byte swapping.
* Array_inputBO(pAry, DAS2ARY_BIG_ENDIAN);
*
* // Read values into the array
* float buf[152] = {0.0f};
* while(fread(buf, sizeof(float), 152, in_file) == 152)
* Array_append(pAry, buf, 152);
*
* // Get the shape of the first index.
* printf("%d records read from %s\n", Array_lengthIn(pAry, DIM0), my_file);
*
* // Print the values in the array, loop below works with ragged arrays and
* // reduces function call overhead by accessing a full record at a time
* float* pVals;
* size_t uVals;
* for(size_t i = 0; i < Array_lengthIn(pAry, DIM0); ++i){
* pVals = Array_getFloatsIn(pAry, DIM1_AT(i), &uVals);
* for(size_t j = 0; j < uVals; ++j){
* if( j > 0) printf(", ");
* printf("%.4e", pVals[j]);
* }
* printf("\n");
* }
*

Public Member Functions

DasArynew_DasAry (const char *id, das_val_type et, size_t sz_each, const void *fill, int rank, size_t *shape, das_units units)
 Creates a new dynamic array buffer. More...
 
unsigned int DasAry_setUsage (DasAry *pThis, unsigned int uFlags)
 Set usage flags to assist arbitrary consumers understand how to use this array. More...
 
unsigned int DasAry_getUsage (DasAry *pThis)
 Returns the usage flags for this array.
 
int inc_DasAry (DasAry *pThis)
 Increment the count of objects using this Das Array. More...
 
int ref_DasAry (const DasAry *pThis)
 Return the reference count of objects using this array.
 
void dec_DasAry (DasAry *pThis)
 Maybe remove the array. More...
 
byte * DasAry_disownElements (DasAry *pThis, size_t *pLen)
 Remove ownership of the underlying element array from this DasArray. More...
 
const char * DasAry_id (const DasAry *pThis)
 Get the name of an array. More...
 
int DasAry_rank (const DasAry *pThis)
 Get the number of dimensions in an array. More...
 
das_units DasAry_units (const DasAry *pThis)
 Get the units for the values in the array.
 
enum das_val_type DasAry_valType (const DasAry *pThis)
 Get the type of value stored in the array if known. More...
 
const char * DasAry_valTypeStr (const DasAry *pThis)
 Get the type of value stored in the array as a text string.
 
char * DasAry_toStr (const DasAry *pThis, char *sInfo, size_t uLen)
 Get a informational string representing the array. More...
 
size_t DasAry_size (const DasAry *pThis)
 Get the total number of data values in an array, regardless of it's shape. More...
 
size_t DasAry_valSize (const DasAry *pThis)
 Get the size in bytes of each element stored in the das array. More...
 
size_t DasAry_lengthIn (const DasAry *pThis, int nIdx, ptrdiff_t *pLoc)
 Return the current max value + 1 for any index. More...
 
int DasAry_shape (const DasAry *pThis, ptrdiff_t *pShape)
 Return current valid ranges for this array indices. More...
 
bool DasAry_validAt (const DasAry *pThis, ptrdiff_t *pLoc)
 Is a valid item located at a complete index. More...
 
const void * DasAry_getAt (const DasAry *pThis, das_val_type et, ptrdiff_t *pLoc)
 Get a pointer to an element at a complete index. More...
 
#define DasAry_getFloatAt(pThis, pLoc)   *((float*)(DasAry_getAt(pThis, vtFloat, pLoc)))
 Wrapper around Array_get for IEEE-754 binary32 (float) More...
 
#define DasAry_getDoubleAt(pThis, pLoc)   *((double*)(DasAry_getAt(pThis, vtDouble, pLoc)))
 Wrapper around Array_get for IEEE-754 binary64 (double) More...
 
#define DasAry_getByteAt(pThis, pLoc)   *((byte*)(DasAry_getAt(pThis, vtByte, pLoc)))
 Wrapper around Array_get for unsigned bytes. More...
 
#define DasAry_getUShortAt(pThis, pLoc)   *((uint16_t*)(DasAry_getAt(pThis, etUint16, pLoc)))
 Wrapper around Array_get for unsigned 16-bit integers. More...
 
#define DasAry_getShortAt(pThis, pLoc)   *((int16_t*)(DasAry_getAt(pThis, etInt16, pLoc)))
 Wrapper around Array_get for signed 16-bit integers. More...
 
#define DasAry_getIntAt(pThis, pLoc)   *((int32_t*)(DasAry_getAt(pThis, etInt32, pLoc)))
 Wrapper around Array_get for 32-bit integers. More...
 
#define DasAry_getLongAt(pThis, pLoc)   *((int64_t*)(DasAry_getAt(pThis, etInt64, pLoc)))
 Wrapper around Array_get for signed 64-bit integers. More...
 
#define DasAry_getTimeAt(pThis, pLoc)   *((das_time*)(DasAry_getAt(pThis, vtTime, pLoc)))
 Wrapper around Array_get for das_time_t structures. More...
 
#define DasAry_getTextAt(pThis, pLoc)   *((char**)(DasAry_getAt(pThis, vtText, pLoc)))
 Wrapper around Array_get for pointers to null-terminated strings. More...
 
bool DasAry_putAt (DasAry *pThis, ptrdiff_t *pStart, const void *pVals, size_t uVals)
 Set values starting at a complete index. More...
 
const void * DasAry_getIn (const DasAry *pThis, das_val_type et, int nDim, ptrdiff_t *pLoc, size_t *pCount)
 Get a pointer to the elements contained by a partial index. More...
 
#define DasAry_getFloatsIn(T,...)   (const float*) DasAry_getIn(T, vtFloat, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getDoublesIn(T,...)   (const double*) DasAry_getIn(T, vtDouble, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getBytesIn(T,...)   (const byte*) DasAry_getIn(T, vtByte, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getUShortsIn(T,...)   (const uint16_t*) DasAry_getIn(T, vtUShort, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getShortsIn(T,...)   (const int16_t*) DasAry_getIn(T, vtShort, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getLongsIn(T,...)   (const int64_t*) DasAry_getIn(T, vtLong, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getTimesIn(T,...)   (const das_time*) DasAry_getIn(T, vtTime, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
#define DasAry_getTextIn(T,...)   (const char**) DasAry_getIn(T, vtText, __VA_ARGS__)
 A wrapper around Array_getIn that casts the output and preforms type checking. More...
 
DasAryDasAry_subSetIn (const DasAry *pThis, const char *id, int nIndices, ptrdiff_t *pLoc)
 Get a lower rank array that is a sub-set of the current array. More...
 
size_t DasAry_qubeIn (DasAry *pThis, int iRecDim)
 Use fill values to make sure the last subset in a dimension is a QUBE. More...
 
bool DasAry_append (DasAry *pThis, const void *pVals, size_t uCount)
 Append some number of items to the end of the array. More...
 
void DasAry_markEnd (DasAry *pThis, int iDim)
 Mark a ragged dimension as finished. More...
 
size_t DasAry_clear (DasAry *pThis)
 Clear all values from the array. More...
 
int DasAry_cmp (DasAry *pThis, const void *vpFirst, const void *vpSecond)
 Compare two items of the type in the array. More...
 
void DasAry_setSrc (DasAry *pThis, int nPktId, size_t uStartItem, size_t uItems)
 Record which packets contain data destine for this array. More...
 

Member Function Documentation

DasAry * new_DasAry ( const char *  id,
das_val_type  et,
size_t  sz_each,
const void *  fill,
int  rank,
size_t *  shape,
das_units  units 
)

Creates a new dynamic array buffer.

Parameters
idThe name of this array. This may be used as a lookup key if an array pointer is stored in a lookup table.
etThe element type, for arbitrary element storage use UNKNOWN, specific types are provided in enum element_type.
sz_eachThe size of each element in the array in bytes. This parameter is only used when the element type is unknown.
fillA pointer to the value for initializing all empty array records. The value should be size_each bytes long. These bytes are copied into the array and this pointer need not remain valid after the constructor call. For unknown types (et = etUnknown) this is a required, non NULL parameter. For known types you can use NULL to automatically set fill to the following values, based on the element_type:
  • etByte 0
  • etUShort 65535
  • etShort -32767
  • etInt -2147483647
  • etLong -9223372036854775807L
  • etFloat -1.0e31
  • etDouble -1.0e31
  • etTime 0000-01-01T00:00:00.000

pFill can point to stack memory as the fill bytes are copied in.

Parameters
rankThe number of dimensions in the array. This sets the number of arguments needed in the get() function call. To make your code easier to read, the defines RANK_1, RANK_2, ... RANK_16 are provided.
shapeThe initial shape of the array. One integer is needed here for each dimension in the array. Use the value 0 to set a dimension to be unbounded. Multi-dimension arrays used to hold an arbitrarily long set of records are typically only unbounded in the first index, though see the example in Array_markEnd for handling multiply ragged arrays.
Returns
A new array buffer allocated on the heap.
* // Create a rank 3 array that is ragged only in the first index, with a
* // fill value of -1.0f, useful for storing a stream of fixed size MARSIS
* // AIS records
* float fill = -1.0f;
* Array* pA = new_Array("fee", etFloat, 0, &fill, RANK_3(0,160,80));
*
* // Create an empty Rank 2 array, that is ragged in both indices.
* // (Useful for Cassini WBR data)
* Array* pA = new_Array("fi", etFloat, 0, NULL, RANK_2(0,0));
*
* // Theoretical example of creating a triply ragged array to hold
* // text from a document, where the first index is the page the
* // second is the line and the third is the byte in a line
* Array* pA = new_Array("text", etByte, 0, NULL, RANK_3(0,0,0));
*
*
Warning
The number of shape parameters must be equal to the rank of the array. The compiler can't check this, but you will get segfaults if the value of rank does not match the number of shape values. To help avoid this the use of the RANK_* macros is highly recommended.
unsigned int DasAry_setUsage ( DasAry pThis,
unsigned int  uFlags 
)

Set usage flags to assist arbitrary consumers understand how to use this array.

Das2 arrays can store co-opertive flags, these do not change the array API but do indicate how the array should be used. The following two usage flags are currently defined:

  • D2ARY_AS_SUBSEQ : Contains Sub-sequences
  • D2ARY_FILL_TERM : Contains FILL terminated sub-sequences
  • D2ARY_AS_STRING : Contains FILL terminated sub-sequences and FILL is 0
Parameters
pThis
uFlagsA flag value to set
Returns
The old flag setting
int inc_DasAry ( DasAry pThis)

Increment the count of objects using this Das Array.

Returns
The new count.
void dec_DasAry ( DasAry pThis)

Maybe remove the array.

Calling this function decrements the reference count for the array. If the count reaches zero all backing buffers (owned by this array) are deleted.

byte * DasAry_disownElements ( DasAry pThis,
size_t *  pLen 
)

Remove ownership of the underlying element array from this DasArray.

Internally all Das Array elements are stored in a single continuous 1-D buffer. When the Das Array is deleted, this buffer is removed as well, if it's owned by the das array.

Implementation detail, the index tracking arrays may still be owned by the Array object and will be deleted when the overall structure is deleted

Parameters
pThisA pointer to a das array structure
pLenA pointer to a variable to hold the length of the element array in elements (not bytes). Use this value to distingu
Returns
A pointer to the raw 1-D element buffer if the Array actually owned the elements, NULL otherwise. Note that buffer memory is not allocated until elements are inserted (lazy allocation) thus an empty array WILL NOT own any elements. So this this function will ALWAYS return NULL for an empty array. Use the value returned by pLen to see if the NULL return was because the array didn't own it's elements or if there were no elements to own.
const char * DasAry_id ( const DasAry pThis)

Get the name of an array.

Parameters
pThisA constant pointer to this array structure
Returns
A constant pointer to the identifier for the array
int DasAry_rank ( const DasAry pThis)

Get the number of dimensions in an array.

Parameters
pThisa pointer to a das array structure
Returns
a value greater than 0 giving the number of dimensions in the array
enum das_val_type DasAry_valType ( const DasAry pThis)

Get the type of value stored in the array if known.

This function is used by dataset objects to know how to cast pointers to different data array values.

Parameters
pThisA constant pointer to this array structure
Returns
A constant pointer to string containing the name for the values in the array, or NULL if the value type has not been set.
char * DasAry_toStr ( const DasAry pThis,
char *  sInfo,
size_t  uLen 
)

Get a informational string representing the array.

Parameters
pThisThe Array in question
sInfopointer to the destination to hold the info string
uLenthe length of the sInfo buffer
Returns
the pointer sInfo
size_t DasAry_size ( const DasAry pThis)

Get the total number of data values in an array, regardless of it's shape.

Parameters
pThisA constant pointer to this array structure
Returns
The total number of items stored in the array, regardless of it's shape.
size_t DasAry_valSize ( const DasAry pThis)

Get the size in bytes of each element stored in the das array.

Parameters
pThisThe Array in question
Returns
The size of each element in bytes
size_t DasAry_lengthIn ( const DasAry pThis,
int  nIdx,
ptrdiff_t *  pLoc 
)

Return the current max value + 1 for any index.

This is a more general version of Array_shape that works for both cubic arrays and those with ragged dimensions. For any index to be inspected, the value of all previous indices must be given. This is less confusing then it sounds, see the example below

See Also
Array_shape For simple arrays that are only ragged in the first index.
Parameters
pThisA pointer to an array object
nIdxThe number of location indices, should be less than the rank in order to get the length of a range of values. The macros DIM0, DIM1_AT, DIM2_AT, etc. are provided which combine this argument and the one below to make calling code more readable, see the example below.
pLocA list of the values for previous indices. The macros DIM1, DIM2_AT, DIM3_AT etc. are provided which combine this argument with the one above to make calling code more readable, see the example below.
Returns
The current maximum valid value for the ith index at current location in the previous indices.
*
* // Here pWBR is a ragged array of all waveform amplitudes taken in a single
* // capture. Dimension 0 corresponds to the capture time point and dimension
* // 1 corresponds to each sample in a capture.
*
* // Print the number of samples in each waveform.
* size_t uWaveforms = Array_lengthIn(pWBR, DIM0);
* for(size_t u = 0; u &lt; uWaveforms; ++u)
* print("Capture %zu has %zu samples\n", u, Array_lengthIn(pWBR, DIM1_AT(u));
*
See Also
Array_getAt to obtain both the length and a pointer to a continuous range of data Values an once.
int DasAry_shape ( const DasAry pThis,
ptrdiff_t *  pShape 
)

Return current valid ranges for this array indices.

See Also
Array_lengthIn
Parameters
pThispointer to an array object
[out]pShapepointer to an array to received the current number of entries in each dimension, should be at least RANK in length. Each element of the output array will be one of the following.
  • An integer from 0 to LONG_MAX to indicate a valid index range
  • The value DASIDX_RAGGED to indicate that the valid index is variable and depends on the values of other indices.
Returns
The rank of the array.
bool DasAry_validAt ( const DasAry pThis,
ptrdiff_t *  pLoc 
)

Is a valid item located at a complete index.

Parameters
pThisA pointer to the array
pLocAn array of indices of length RANK. A rank 1 Das Array requires two indices to access an element, a rank 2 requires three, etc. The macros LOC_1, LOC_2, etc have been provided to make code more readable. See the example below.
Returns
true the location list refers to a valid array index set. False otherwise. Not that the actual value at the index may be a fill value.
* Array* pAry = new_Array("amplitudes", FLOAT, NULL, RANK_3(0, 160, 80));
*
* size_t uRec = 0;
* // See if we have a complete MARSIS frame for this record...
* if(! Array_validAt(pAry, IDX3(uRec, 159, 79)))
* fprintf(stderr, "Error: Short frame count in record %zu", uRec);
*
const void * DasAry_getAt ( const DasAry pThis,
das_val_type  et,
ptrdiff_t *  pLoc 
)

Get a pointer to an element at a complete index.

For type safety the macros Array_getFloat, Array_getDouble, etc have been provided and should be used instead of the base function here.

Parameters
pThisA pointer to the array
etThe element type pointer expected at the given location, this is used by the type checking macros Array_getFloat and friends.
pLocAn array of indices of length RANK. A rank 2 Das Array requires two indices to access an element, a rank 3 requires three, etc. The macros IDX1, IDX2, IDX3, etc have been provided to make code more readable. See the example below.
Returns
a pointer to value at the given indices, or NULL if that location is not valid and das_return_on_error() has been called.
* // Uses type checking macro's
* das_time_t dt = Array_getTimeAt(pAry, IDX1(uRec));
*
* // Get last event, whereever it is
* const char* sEvent = Array_getTextAt(pAry, IDX1(-1));
*
See Also
Array_getIn to access multiple Values at once avoiding function call overhead in tight loops.
bool DasAry_putAt ( DasAry pThis,
ptrdiff_t *  pStart,
const void *  pVals,
size_t  uVals 
)

Set values starting at a complete index.

Note, this will not expand the size of the array. Use the function append() to automatically grow the array to store the desired number of items.

Parameters
pThisA pointer to the array
pStartThe complete index to the starting point to write values, use the macros IDX1, IDX2, etc. to make calling code more readable
pValsThe values to write
uValsThe number of values to write
Returns
true if the items could be written, false if the array is not large enough to hold all the values or if any other error is encountered
const void * DasAry_getIn ( const DasAry pThis,
das_val_type  et,
int  nDim,
ptrdiff_t *  pLoc,
size_t *  pCount 
)

Get a pointer to the elements contained by a partial index.

Parameters
pThisA Array containing the data of interest
etThe expected type of element to be returned. This is used by the type safe macros Array_getDoubleAt, Array_getTextAt, etc.
nDimThe number of location indices, should be less than the rank in order to get the length of a range of values. The macros DIM0, DIM1_AT, DIM2_AT, etc. are provided which combine this argument and the one below to make calling code more readable, see the example below.
pLocAn array of location indices, nIndices long. Use the macros DIM0, DIM1_AT, DIM2_AT, etc. for cleaner code.
pCountA pointer to a variable to hold the number of elements under the given index. If nIndices is equal to the array rank the returned value will be at most 1.
Returns
A pointer a continuous subset of elements, or NULL if no elements are located at the given index set. You will have to cast this pointer to the element type.
* // Print all the events in an array
* size_t uVals;
* char** events = Array_getTextIn(pAry, DIM1, &uVals);
* for(size_t u = 0; u < uVals; ++u)
* printf("Event %06zu: %s\n", u, events[u]);
*
* // Print all the magnetic amplitudes for a single time slice at index 117
* size_t uVals;
* float* pAmp = Array_getFloatsIn(pAry, DIM2_AT(117), &uVals);
* for(size_t u = 0; u < uVals; ++u)
* printf("Amp at freq %03zu: %s nT**2/Hz \n", u, events[u]);
*
*
DasAry * DasAry_subSetIn ( const DasAry pThis,
const char *  id,
int  nIndices,
ptrdiff_t *  pLoc 
)

Get a lower rank array that is a sub-set of the current array.

For some given number of indices, produce a sub-array. This is similar to Array_getAt but produces a whole new Array object whose data are provided stored in a separate Array.

* // Get all data for the 10th record of a 2-D dataset, would often be a
* // time slice for das2 streams.
* Array* pRec = Array_subSetIn(pAllData, INDEX_0, 10);
*
* // Get the time delays for frequency index 100 for time point 22 of a
* // MARSIS AIS data stream
* Array* pDelays = Array_subSetIn(pAllData, INDEX_1, 22, 100);
*
Parameters
pThis
idA identifing name for the new sub-array
nIndicesThe number of location indices, should be less than the rank in order to get a range of values. Use the macros DIM0, DIM1_AT, DIM2_AT, etc. for cleaner code.
pLocAn array of location indices, nIndices long. Use the macros DIM0, DIM1_AT, DIM2_AT, etc. for cleaner code.
Returns
A new Array allocated on the heap that does not own it's backing buffer.
size_t DasAry_qubeIn ( DasAry pThis,
int  iRecDim 
)

Use fill values to make sure the last subset in a dimension is a QUBE.

Parameters
pThisthe array
iRecDimThe dimension to qube, typically the last dimension in the array, dimensions are numbered starting from 0. Use the macro's DIM1, DIM2, etc. to make the code more readable. Dimension 0 can't be marked as ended and the macro DIM0 will not work here.
Returns
the number of fill values added to the array
* Array* pAry = new_Array("marsis", etFloat, 0, NULL, RANK_3(0, 160, 80));
*
* //Example 1: Read a complete sets of delay times
* float buf[80];
* size_t uRead = fread(buf, sizeof(float), 80, stdin);
* Array_append(pAry, buf, uRead);
* Array_qubeIn(pAry, DIM2);
*
* //Example 2: Read in complete ionograms
* float buf[160*80];
* size_t uRead = fread(buf, sizeof(float), 80*160, stdin);
* Array_append(pAry, buf, uRead);
* Array_qubeIn(pAry, DIM1);
*
*
See Also
DasAry_append
bool DasAry_append ( DasAry pThis,
const void *  pVals,
size_t  uCount 
)

Append some number of items to the end of the array.

This works as you would expect for all arrays that are only ragged in the 0th dimension.

See Also
Array_markEnd. Arrays that are ragged in dimension other that the 0th need some way to know that it's Time to roll the index back to 0 on the next append operation, Array_markEnd sets the needed flags.
Parameters
pThisThe array which should copy in the new values.
pValsA constant pointer to values to add
uCountThe number of values to add
Returns
true if uCount items were appended to the array, false otherwise
void DasAry_markEnd ( DasAry pThis,
int  iDim 
)

Mark a ragged dimension as finished.

Parameters
pThisThe das array
iDimThe dimension which should have it's index rolled back to zero on the next insert. Marking the end of a low index (say 1) automatically marks the end of any higher indices (ex 2,3).
* // Read in lines of text into an array that stores data by page number,
* // line number and the byte number. Input processing is simplistic in
* // order to focus on Array calls.
*
* byte fill = 0;
* Array* pAry = new_Array("source", etByte, 0, &fill, RANK_3(0,0,0));
* char sBuf[1024] = {'\0'};
* size_t uLen = 0;
* while(!eof(stdin)){
* while(fgets(sBuf, 1024, stdin)){
* uLen = strlen(sBuf);
* if(sBuf[0] == 0x0C) Array_markEnd(pAry, DIM1); // end page
* Array_append(pAry, sBuf, uLen+1); // keep NULL terminators
* if(sBuf[uLen - 1] == '\n') Array_markEnd(pAry, DIM2); // end line
* }
* }
*
size_t DasAry_clear ( DasAry pThis)

Clear all values from the array.

This operation internally just resets the count of items to 0 in all arrays it does not free memory. Dimensions above the 0th retain their shape.

Parameters
pThisThe array to clear
Returns
then number of items cleared
int DasAry_cmp ( DasAry pThis,
const void *  vpFirst,
const void *  vpSecond 
)

Compare two items of the type in the array.

Returns
A value less than zero if *pFirst is less than *pSecond, a value greater than zero if *pFirst is greater than *pSecond and 0 if both values are equal
void DasAry_setSrc ( DasAry pThis,
int  nPktId,
size_t  uStartItem,
size_t  uItems 
)

Record which packets contain data destine for this array.

Parameters
pThisThe array
nPktIdThe id of the Das packet which contains values that should be added to this array
uStartItemThe location in the packet where this array's data starts
uItemsThe number of items to add from each packet

The documentation for this struct was generated from the following file: