ASN1C C/C++ Common Runtime  ASN1C v7.6.x
rtxCharStr.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2003-2022 Objective Systems, Inc.
3  *
4  * This software is furnished under a license and may be used and copied
5  * only in accordance with the terms of such license and with the
6  * inclusion of the above copyright notice. This software or any other
7  * copies thereof may not be provided or otherwise made available to any
8  * other person. No title to and ownership of the software is hereby
9  * transferred.
10  *
11  * The information in this software is subject to change without notice
12  * and should not be construed as a commitment by Objective Systems, Inc.
13  *
14  * PROPRIETARY NOTICE
15  *
16  * This software is an unpublished work subject to a confidentiality agreement
17  * and is protected by copyright and trade secret law. Unauthorized copying,
18  * redistribution or other use of this work is prohibited.
19  *
20  * The above notice of copyright on this source code product does not indicate
21  * any actual or intended publication of such source code.
22  *
23  *****************************************************************************/
33 #ifndef _RTXCHARSTR_H_
34 #define _RTXCHARSTR_H_
35 
36 #include "rtxsrc/rtxContext.h"
37 
38 #ifdef __cplusplus
39 extern "C" {
40 #endif
41 
51 EXTERNRT int rtxStricmp (const char* str1, const char* str2);
52 
63 EXTERNRT int rtxStrnicmp (const char* str1, const char* str2, size_t count);
64 
75 EXTERNRT char* rtxStrcat (char* dest, size_t bufsiz, const char* src);
76 
88 EXTERNRT char* rtxStrncat
89 (char* dest, size_t bufsiz, const char* src, size_t nchars);
90 
101 EXTERNRT char* rtxStrcpy (char* dest, size_t bufsiz, const char* src);
102 
118 EXTERNRT char* rtxStrncpy
119 (char* dest, size_t bufsiz, const char* src, size_t nchars);
120 
132 EXTERNRT char* rtxStrdup (OSCTXT* pctxt, const char* src);
133 
146 EXTERNRT char* rtxStrndup (OSCTXT* pctxt, const char* src, OSSIZE nchars);
147 
161 EXTERNRT const char* rtxStrJoin
162 (char* dest, size_t bufsiz, const char* str1, const char* str2,
163  const char* str3, const char* str4, const char* str5);
164 
177 EXTERNRT char* rtxStrDynJoin
178 (OSCTXT* pctxt, const char* str1, const char* str2,
179  const char* str3, const char* str4, const char* str5);
180 
187 EXTERNRT char* rtxStrTrimEnd (char* s);
188 
206 EXTERNRT int rtxValidateConstrainedStr(OSCTXT *pctxt, const char *pvalue,
207  const char *pCharSet);
208 
219 EXTERNRT int rtxIntToCharStr
220 (OSINT32 value, char* dest, size_t bufsiz, char padchar);
221 
232 EXTERNRT int rtxUIntToCharStr
233 (OSUINT32 value, char* dest, size_t bufsiz, char padchar);
234 
235 #if !defined(_NO_INT64_SUPPORT)
236 
246 EXTERNRT int rtxInt64ToCharStr
247 (OSINT64 value, char* dest, size_t bufsiz, char padchar);
248 
259 EXTERNRT int rtxUInt64ToCharStr
260 (OSUINT64 value, char* dest, size_t bufsiz, char padchar);
261 
262 #endif /* !defined(_NO_INT64_SUPPORT) */
263 
274 EXTERNRT int rtxSizeToCharStr
275 (size_t value, char* dest, size_t bufsiz, char padchar);
276 
287 EXTERNRT int rtxHexCharsToBinCount (const char* hexstr, size_t nchars);
288 
301 EXTERNRT int rtxHexCharsToBin
302 (const char* hexstr, size_t nchars, OSOCTET* binbuf, size_t bufsize);
303 
313 EXTERNRT int rtxCharStrToInt (const char* cstr, OSINT32* pvalue);
314 
327 EXTERNRT int rtxCharStrnToInt
328 (const char* cstr, OSSIZE ndigits, OSINT32* pvalue);
329 
339 EXTERNRT int rtxCharStrToInt8 (const char* cstr, OSINT8* pvalue);
340 
351 EXTERNRT int rtxCharStrToInt16 (const char* cstr, OSINT16* pvalue);
352 
363 EXTERNRT int rtxCharStrToInt64 (const char* cstr, OSINT64* pvalue);
364 
375 EXTERNRT int rtxCharStrToUInt (const char* cstr, OSUINT32* pvalue);
376 
387 EXTERNRT int rtxCharStrToUInt8 (const char* cstr, OSUINT8* pvalue);
388 
399 EXTERNRT int rtxCharStrToUInt16 (const char* cstr, OSUINT16* pvalue);
400 
411 EXTERNRT int rtxCharStrToUInt64 (const char* cstr, OSUINT64* pvalue);
412 
416 #ifdef __cplusplus
417 }
418 #endif
419 
420 #endif
int rtxCharStrToUInt8(const char *cstr, OSUINT8 *pvalue)
int rtxCharStrToUInt16(const char *cstr, OSUINT16 *pvalue)
int rtxCharStrToInt8(const char *cstr, OSINT8 *pvalue)
int rtxCharStrToInt16(const char *cstr, OSINT16 *pvalue)
int rtxCharStrToInt(const char *cstr, OSINT32 *pvalue)
int rtxUIntToCharStr(OSUINT32 value, char *dest, size_t bufsiz, char padchar)
int rtxCharStrToUInt64(const char *cstr, OSUINT64 *pvalue)
int rtxIntToCharStr(OSINT32 value, char *dest, size_t bufsiz, char padchar)
int rtxHexCharsToBin(const char *hexstr, size_t nchars, OSOCTET *binbuf, size_t bufsize)
char * rtxStrcat(char *dest, size_t bufsiz, const char *src)
int rtxCharStrToUInt(const char *cstr, OSUINT32 *pvalue)
int rtxStrnicmp(const char *str1, const char *str2, size_t count)
int rtxInt64ToCharStr(OSINT64 value, char *dest, size_t bufsiz, char padchar)
int rtxHexCharsToBinCount(const char *hexstr, size_t nchars)
int rtxValidateConstrainedStr(OSCTXT *pctxt, const char *pvalue, const char *pCharSet)
char * rtxStrDynJoin(OSCTXT *pctxt, const char *str1, const char *str2, const char *str3, const char *str4, const char *str5)
const char * rtxStrJoin(char *dest, size_t bufsiz, const char *str1, const char *str2, const char *str3, const char *str4, const char *str5)
int rtxCharStrnToInt(const char *cstr, OSSIZE ndigits, OSINT32 *pvalue)
char * rtxStrncat(char *dest, size_t bufsiz, const char *src, size_t nchars)
char * rtxStrcpy(char *dest, size_t bufsiz, const char *src)
char * rtxStrTrimEnd(char *s)
int rtxCharStrToInt64(const char *cstr, OSINT64 *pvalue)
char * rtxStrndup(OSCTXT *pctxt, const char *src, OSSIZE nchars)
int rtxStricmp(const char *str1, const char *str2)
int rtxUInt64ToCharStr(OSUINT64 value, char *dest, size_t bufsiz, char padchar)
int rtxSizeToCharStr(size_t value, char *dest, size_t bufsiz, char padchar)
Definition: rtxContext.h:198
char * rtxStrdup(OSCTXT *pctxt, const char *src)
char * rtxStrncpy(char *dest, size_t bufsiz, const char *src, size_t nchars)