Dashboard > Appistry EAF v3.8 > ... > C FAM API Linux > fabric_array.h
Log In   View a printable version of the current page.  
  fabric_array.h

fab_array_new

fab_array* fab_array_new()

This function allocates memory for an array.

Return Value
fab_array* pointer to new fab_array object

fab_array_free

void fab_array_free(fab_array* a)

This function releases the memory allocated to an array.

Parameters
fab_array* fab_array object pointer passed into the function

fab_array_copy

void fab_array_copy(fab_array* dest,
                    fab_array* src)

This function creates a copy of the existing array.

Parameters
fab_array* destination fab_array object pointer passed into the function
fab_array* source fab_array object pointer passed into the function

fab_array_size

size_t fab_array_size(fab_array* a)

This function returns the number of elements in the array.

Parameters
fab_array* fab_array object pointer passed into the function
Return Value
size_t number of elements

fab_array_push_new

fab_value* fab_array_push_new(fab_array* a)

This function creates a new empty value, pushes it onto the end of the array, and returns an identifier for the value.

Parameters
fab_array* fab_array object pointer passed into the function
Return Value
fab_value* pointer to new fab_value object

fab_array_erase_value

void fab_array_erase_value(fab_array* a,
                           size_t idx)

This function removes the value at index, and adjusts the position of the remaining elements.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index

fab_array_push_value

void fab_array_push_value(fab_array* a,
                          const fab_value* val)

This function pushes a fab_value onto the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
fab_value* const pointer to fab_value object

fab_array_set_value

void fab_array_set_value(fab_array* a,
                         size_t idx,
                         const fab_value* val)

This function copies an existing fab_value to a specific place in the array.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
fab_value* const pointer to fab_value object

fab_array_get_value

fab_value* fab_array_get_value(fab_array* a,
                               size_t idx)

This function returns the value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
fab_value* pointer to fab_value object

fab_array_get_value_size

size_t fab_array_get_value_size(fab_array* a,
                                size_t idx)

This function returns the size of a value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
size_t size value

fab_array_push_string

void fab_array_push_string(fab_array* a,
                           const char* s)

This function pushes the string value to the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
const char* string value

fab_array_set_string

void fab_array_set_string(fab_array* a,
                          size_t idx,
                          const char* s)

This function sets the string value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
const char* string value

fab_array_get_string

const char* fab_array_get_string(fab_array* a,
                                 size_t idx)

This function returns the string value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
const char* string value

fab_array_push_int

void fab_array_push_int(fab_array* a,
                        int n)

This function pushes a 32-bit integer value onto the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
int integer value

fab_array_set_int

void fab_array_set_int(fab_array* a,
                       size_t idx,
                       int n)

This function sets a 32-bit integer value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
int integer value

fab_array_get_int

int fab_array_get_int(fab_array* a,
                      size_t idx)

This function returns a 32-bit integer value in the array from a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
int integer value

fab_array_push_uint

void fab_array_push_uint(fab_array* a,
unsigned int n)

This function pushes a 32-bit unsigned integer value to the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
unsigned int unsigned integer value

fab_array_set_uint

void fab_array_set_uint(fab_array* a,
                        size_t idx,
                        unsigned int n)

This function sets a 32-bit unsigned integer value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
unsigned int unsigned integer value

fab_array_get_uint

unsigned int fab_array_get_uint(fab_array* a,
                                size_t idx)

This function returns a 32-bit unsigned integer value in the array from a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
unsigned int unsigned integer value

fab_array_push_float

void fab_array_push_float(fab_array* a,
                          float n)

This function pushes a floating-point value to the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
float floating-point value

fab_array_set_float

void fab_array_set_float(fab_array* a,
                         size_t idx,
                         float n)

This function sets the floating-point value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
float floating-point value

fab_array_get_float

float fab_array_get_float(fab_array* a,
                          size_t idx)

This function returns a floating-point value in the array from a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
float floating-point value

fab_array_push_double

void fab_array_push_double(fab_array* a,
                           double n)

This function pushes a double precision value to the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
double double precision value

fab_array_set_double

void fab_array_set_double(fab_array* a,
                          size_t idx,
                          double n)

This function sets the double precision value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
double double precision value

fab_array_get_double

double fab_array_get_double(fab_array* a,
                            size_t idx)

This function returns a double precision value in the array from a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
double double precision value

fab_array_push_int64

void fab_array_push_int64(fab_array* a,
                          fab_int64 n)

This function pushes a 64-bit integer value onto the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
fab_int64 64-bit integer value

fab_array_set_int64

void fab_array_set_int64(fab_array* a,
                         size_t idx,
                         fab_int64 n)

This function sets a 64-bit integer value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
fab_int64 64-bit integer value

fab_array_get_int64

fab_int64 fab_array_get_int64(fab_array* a,
                              size_t idx)

This function returns a 64-bit integer value in the array from a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
fab_int64 64-bit integer value

fab_array_push_uint64

void fab_array_push_uint64(fab_array* a,
                           fab_uint64 n)

This function pushes the unsigned 64-bit integer value onto the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
fab_uint64 unsigned 64-bit integer value

fab_array_set_uint64

void fab_array_set_uint64(fab_array* a,
                          size_t idx,
                          fab_uint64 n)

This function sets an unsigned 64-bit integer value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
fab_uint64 unsigned 64-bit integer value

fab_array_get_uint64

fab_uint64 fab_array_get_uint64(fab_array* a,
                                size_t idx)

This function returns an unsigned 64-bit integer value in the array from a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
fab_uint64 unsigned 64-bit integer value

fab_array_push_binary

void fab_array_push_binary(fab_array* a,
                           const void* data,
                           size_t data_len)

This function pushes a binary value to the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
const void* const void pointer to data buffer
size_t index

fab_array_set_binary

void fab_array_set_binary(fab_array* a,
                          size_t idx,
                          const void* data,
                          size_t data_len)

This function sets the binary value in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
const void* const void pointer to data buffer
size_t length of the data

fab_array_get_binary

size_t fab_array_get_binary(fab_array* a,
                            size_t idx,
                            size_t max_buf_size,
                            void* buf)

This function gets a binary value from the array at a specific index into the buffer, and returns the size of the buffer.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
size_t buffer size
void* void pointer to data buffer
Return Value
size_t size of data buffer

fab_array_push_map

void fab_array_push_map(fab_array* a,
                        fab_map* m)

This function pushes a map onto the end of the array.

Parameters
fab_array* fab_array object pointer passed into the function
fab_map* pointer to fab_map object

fab_array_set_map

void fab_array_set_map(fab_array* a,
                       size_t idx,
                       fab_map* m)

This function sets an existing map in the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
fab_map* pointer to fab_map object

fab_array_get_map

fab_map* fab_array_get_map(fab_array* a,
                           size_t idx)

This function returns the map from the array at a specific index.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
fab_map* pointer to fab_map object

fab_array_push_array

void fab_array_push_array(fab_array* main_array,
                          fab_array* array_to_push)

This function pushes an array onto the end of another array.

Parameters
fab_array* main fab_array object pointer passed into the function
fab_array* existing fab_array object pointer passed into the function to be added to main fab_array

fab_array_set_array

void fab_array_set_array(fab_array* main_array,
                         size_t idx,
                         fab_array* array_to_set)

This function sets an array in the main array at a specific index.

Parameters
fab_array* main fab_array object pointer passed into the function
size_t index
fab_array* existing fab_array object pointer passed into the function to be set into main array

fab_array_get_array

fab_array* fab_array_get_array(fab_array* main_array,
                               size_t idx)

This function returns the array stored at a specific index in the main array.

Parameters
fab_array* fab_array object pointer passed into the function
size_t index
Return Value
fab_array* fab_array object pointer