ASN1C C/C++ Common Runtime  ASN1C v7.8.x
rtxPrintStream.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 1997-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  *****************************************************************************/
29 #ifndef _RTXPRINTSTREAM_H_
30 #define _RTXPRINTSTREAM_H_
31 
32 #include <stdarg.h>
33 #include "rtxsrc/rtxContext.h"
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
37 
45 typedef void (*rtxPrintCallback)
46 (void* pPrntStrmInfo, const char* fmtspec, va_list arglist);
47 
51 typedef struct OSRTPrintStream {
52  rtxPrintCallback pfPrintFunc;
53  void * pPrntStrmInfo;
55 
56 #ifndef __SYMBIAN32__
57 
61 #endif
62 
78 EXTERNRT int rtxSetPrintStream
79 (OSCTXT *pctxt, rtxPrintCallback myCallback, void* pStrmInfo);
80 
81 #ifndef __SYMBIAN32__
82 
94 EXTERNRT int rtxSetGlobalPrintStream
95 (rtxPrintCallback myCallback, void* pStrmInfo);
96 #endif
97 
111 EXTERNRT int rtxPrintToStream (OSCTXT* pctxt, const char* fmtspec, ...);
112 
126 EXTERNRT int rtxDiagToStream
127 (OSCTXT *pctxt, const char* fmtspec, va_list arglist);
128 
137 EXTERNRT int rtxPrintStreamRelease (OSCTXT* pctxt);
138 
156 EXTERNRT void rtxPrintStreamToStdoutCB
157 (void* pPrntStrmInfo, const char* fmtspec, va_list arglist);
158 
175 EXTERNRT void rtxPrintStreamToFileCB
176 (void* pPrntStrmInfo, const char* fmtspec, va_list arglist);
177 
178 typedef struct {
179  char* strbuf;
180  OSSIZE bufsize;
181  OSSIZE endx;
182 } OSRTStrBuf;
183 
199 EXTERNRT void rtxPrintStreamToStringCB
200 (void* pPrntStrmInfo, const char* fmtspec, va_list arglist);
201 
202 #ifdef __cplusplus
203 }
204 #endif
205 
209 #endif /* _RTXPRINTSTREAM_H_ */
210 
Definition: rtxPrintStream.h:178
int rtxPrintStreamRelease(OSCTXT *pctxt)
int rtxDiagToStream(OSCTXT *pctxt, const char *fmtspec, va_list arglist)
int rtxPrintToStream(OSCTXT *pctxt, const char *fmtspec,...)
void rtxPrintStreamToFileCB(void *pPrntStrmInfo, const char *fmtspec, va_list arglist)
OSRTPrintStream g_PrintStream
int rtxSetGlobalPrintStream(rtxPrintCallback myCallback, void *pStrmInfo)
Definition: rtxPrintStream.h:51
void(* rtxPrintCallback)(void *pPrntStrmInfo, const char *fmtspec, va_list arglist)
Definition: rtxPrintStream.h:46
void rtxPrintStreamToStringCB(void *pPrntStrmInfo, const char *fmtspec, va_list arglist)
void rtxPrintStreamToStdoutCB(void *pPrntStrmInfo, const char *fmtspec, va_list arglist)
int rtxSetPrintStream(OSCTXT *pctxt, rtxPrintCallback myCallback, void *pStrmInfo)
struct OSRTPrintStream OSRTPrintStream
Definition: rtxContext.h:198