MRPT  1.9.9
XsArrayDescriptor Struct Reference

Detailed Description

This object describes how to treat the data in an array.

Ususally there is one static instance per type of array that will be used by all XsArrays of that type.

Definition at line 63 of file xsarray.h.

#include <xSens_MT4/xstypes/include/xsens/xsarray.h>

Public Attributes

const XsSize itemSize
 The size of an array item in bytes. More...
 
void(* itemSwap )(void *a, void *b)
 The function to use for swapping the data of two array items. More...
 
void(* itemConstruct )(void *e)
 The function to use for constructing a new array item. More...
 
void(* itemCopyConstruct )(void *e, void const *s)
 The function to use for constructing a new array item with a source initializer. More...
 
void(* itemDestruct )(void *e)
 The function to use for destructing a array item. More...
 
void(* itemCopy )(void *to, void const *from)
 The function to use for copying the data of from to to. More...
 
int(* itemCompare )(void const *a, void const *b)
 The function to use for comparing two items. More...
 

Member Data Documentation

◆ itemCompare

int(* XsArrayDescriptor::itemCompare) (void const *a, void const *b)

The function to use for comparing two items.

Parameters
aLeft hand side of comparison.
bRight hand side of comparison.
Returns
The function will return 0 when the items are equal. When greater/less comparison is possible, the function should return < 0 if a < b and > 0 if a > b.

Definition at line 95 of file xsarray.h.

◆ itemConstruct

void(* XsArrayDescriptor::itemConstruct) (void *e)

The function to use for constructing a new array item.

May be 0 for simple types.

Parameters
ePointer to item to construct.

Definition at line 80 of file xsarray.h.

◆ itemCopy

void(* XsArrayDescriptor::itemCopy) (void *to, void const *from)

The function to use for copying the data of from to to.

Parameters
toPointer to item to copy to.
fromPointer to item to copy from.

Definition at line 90 of file xsarray.h.

◆ itemCopyConstruct

void(* XsArrayDescriptor::itemCopyConstruct) (void *e, void const *s)

The function to use for constructing a new array item with a source initializer.

This may not be 0.

Parameters
ePointer to item to construct.
sPointer to source item to copy from.

Definition at line 84 of file xsarray.h.

◆ itemDestruct

void(* XsArrayDescriptor::itemDestruct) (void *e)

The function to use for destructing a array item.

May be 0 for simple types.

Parameters
ePointer to item to destruct.

Definition at line 87 of file xsarray.h.

◆ itemSize

const XsSize XsArrayDescriptor::itemSize

The size of an array item in bytes.

Definition at line 73 of file xsarray.h.

◆ itemSwap

void(* XsArrayDescriptor::itemSwap) (void *a, void *b)

The function to use for swapping the data of two array items.

Parameters
aPointer to first item to swap.
bPointer to second item to swap.

Definition at line 77 of file xsarray.h.




Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 8fe78517f Sun Jul 14 19:43:28 2019 +0200 at lun oct 28 02:10:00 CET 2019