RTI Connext DDS Micro C API  Version 3.0.0.1
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
osapi_hash.h File Reference

Generic hash interface definition. More...

#include "osapi/osapi_dll.h"
#include "osapi/osapi_types.h"

Go to the source code of this file.

Functions

void OSAPI_Hash_initialize (OSAPI_Hash *self)
 initialize a OSAPI_Hash
RTI_BOOL OSAPI_Hash_equals (const OSAPI_Hash *a, const OSAPI_Hash *b)
 Checks if two OSAPI_Hash are equal.
int OSAPI_Hash_compare (const OSAPI_Hash *a, const OSAPI_Hash *b)
 Compare two hashes.
void OSAPI_Hash_copy (OSAPI_Hash *out, const OSAPI_Hash *in)
 Copy a hash.
RTI_BOOL OSAPI_Hash_is_valid (const OSAPI_Hash *self)
 Check if a OSAPI_Hash is valid.
RTI_UINT8 OSAPI_Hash_length (const OSAPI_Hash *self)
 Returns the length in bytes of the OSAPI_Hash.
const RTI_UINT8 * OSAPI_Hash_value (const OSAPI_Hash *self)
 Returns a array containing the OSAPI_Hash value.
void OSAPI_Hash_reset (OSAPI_Hash *self)
 Marks a hash as invalid.
void OSAPI_Hash_print (const OSAPI_Hash *self)
 Print a RTISampleHash.
void OSAPI_Hash_compute_md5 (OSAPI_Hash *self, const char *in, unsigned int size)
 Computes the MD5 of a buffer.
void OSAPI_Hash_compute_scatter_md5 (OSAPI_Hash *self, const char **in, unsigned int size, const unsigned int *elementSize)
 Computes the MD5 of a set of buffers and store the result in the output OSAPI_Hash.

Detailed Description

Generic hash interface definition.


Function Documentation

void OSAPI_Hash_initialize ( OSAPI_Hash *  self)

initialize a OSAPI_Hash

Parameters:
selfIn. The hash to initialize
RTI_BOOL OSAPI_Hash_equals ( const OSAPI_Hash *  a,
const OSAPI_Hash *  b 
)

Checks if two OSAPI_Hash are equal.

Parameters:
aIn. The first hash to compare
bIn. The second hash to compare
Returns:
RTI_TRUE if they are equal. RTI_FALSE otherwise
int OSAPI_Hash_compare ( const OSAPI_Hash *  a,
const OSAPI_Hash *  b 
)

Compare two hashes.

Parameters:
aIn. The first OSAPI_Hash to compare
bIn. The first OSAPI_Hash to compare
Returns:
Return 0 if they are equal.
void OSAPI_Hash_copy ( OSAPI_Hash *  out,
const OSAPI_Hash *  in 
)

Copy a hash.

Parameters:
outOut. The OSAPI_Hash where to copy
inIn. The source OSAPI_Hash
RTI_BOOL OSAPI_Hash_is_valid ( const OSAPI_Hash *  self)

Check if a OSAPI_Hash is valid.

Parameters:
selfIn. The OSAPI_Hash to check
RTI_UINT8 OSAPI_Hash_length ( const OSAPI_Hash *  self)

Returns the length in bytes of the OSAPI_Hash.

Parameters:
selfIn. The OSAPI_Hash to get the length
Returns:
the length in bytes of the hash
const RTI_UINT8* OSAPI_Hash_value ( const OSAPI_Hash *  self)

Returns a array containing the OSAPI_Hash value.

Parameters:
selfIn. The OSAPI_Hash to get the length
Returns:
A pointer to the octet buffer containing the hash
void OSAPI_Hash_reset ( OSAPI_Hash *  self)

Marks a hash as invalid.

Parameters:
selfIn. The OSAPI_Hash to reset
void OSAPI_Hash_print ( const OSAPI_Hash *  self)

Print a RTISampleHash.

Parameters:
selfIn. The OSAPI_Hash to print
void OSAPI_Hash_compute_md5 ( OSAPI_Hash *  self,
const char *  in,
unsigned int  size 
)

Computes the MD5 of a buffer.

Parameters:
selfOut. The output OSAPI_Hash
inIn. The buffer to calculate the hash value
sizeIn. The length of the buffer
void OSAPI_Hash_compute_scatter_md5 ( OSAPI_Hash *  self,
const char **  in,
unsigned int  size,
const unsigned int *  elementSize 
)

Computes the MD5 of a set of buffers and store the result in the output OSAPI_Hash.

Parameters:
selfOut. The output OSAPI_Hash
inIn. Array of buffers that will be used to calculate the hash value
sizeIn. The number of elements in the array of buffers
elementSizeIn. An array containing the size of the buffers in the in parameter

RTI Connext DDS Micro C API Version 3.0.0.1 Copyright © Mon Aug 5 2019 Real-Time Innovations, Inc