RTI Connext DDS Micro C API  Version 4.1.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
OSAPI String API

Functions

RTI_SIZE_T OSAPI_String_length (const char *s)
 Return length of ASCIIZ string.
RTI_INT32 OSAPI_String_cmp (const char *left, const char *right)
 Compare two ASCIIZ strings.
RTI_INT32 OSAPI_String_ncmp (const char *left, const char *right, RTI_SIZE_T num)
 Return the process ID.

Detailed Description


Function Documentation

RTI_SIZE_T OSAPI_String_length ( const char *  s)

Return length of ASCIIZ string.

Return length of ASCIIZ string not including \0.

Parameters:
[in]sPointer to beginning of byte string.
Returns:
Length of string not including \0.
RTI_INT32 OSAPI_String_cmp ( const char *  left,
const char *  right 
)

Compare two ASCIIZ strings.

Lexicographically compare the null-terminated strings l and r. The comparison is using unsigned arithmetic.

Parameters:
[in]leftLeft side string.
[in]rightRight side string.
Returns:
0 if the strings are identical, a positive integer if left is greater then right, and a negative integer if left less then right.
RTI_INT32 OSAPI_String_ncmp ( const char *  left,
const char *  right,
RTI_SIZE_T  num 
)

Return the process ID.

Lexicographically compare null-terminated strings l and r, including up to num characters (if the null terminator is not found before the specified number of characters has been compared). The comparison uses unsigned arithmetic.

Parameters:
[in]leftLeft side string.
[in]rightRight side string.
[in]numMaximum number of characters to compare.
Returns:
0 if the strings are identical, a positive integer if left is greated than right, and a negative integer if left is less than right.

RTI Connext DDS Micro C API Version 4.1.0 Copyright © Sun Dec 8 2024 Real-Time Innovations, Inc