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:
-
self | In. 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:
-
a | In. The first hash to compare |
b | In. 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:
-
a | In. The first OSAPI_Hash to compare |
b | In. 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:
-
out | Out. The OSAPI_Hash where to copy |
in | In. The source OSAPI_Hash |
RTI_BOOL OSAPI_Hash_is_valid |
( |
const OSAPI_Hash * |
self | ) |
|
Check if a OSAPI_Hash is valid.
- Parameters:
-
self | In. The OSAPI_Hash to check |
RTI_UINT8 OSAPI_Hash_length |
( |
const OSAPI_Hash * |
self | ) |
|
Returns the length in bytes of the OSAPI_Hash.
- Parameters:
-
self | In. 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:
-
self | In. 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:
-
self | In. The OSAPI_Hash to reset |
void OSAPI_Hash_print |
( |
const OSAPI_Hash * |
self | ) |
|
Print a RTISampleHash.
- Parameters:
-
self | In. 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:
-
self | Out. The output OSAPI_Hash |
in | In. The buffer to calculate the hash value |
size | In. 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:
-
self | Out. The output OSAPI_Hash |
in | In. Array of buffers that will be used to calculate the hash value |
size | In. The number of elements in the array of buffers |
elementSize | In. An array containing the size of the buffers in the in parameter |