ASN1C C/C++ Common Runtime  ASN1C v7.7.x
rtxStack.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2003-2023 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  *****************************************************************************/
28 #ifndef _RTXSTACK_H_
29 #define _RTXSTACK_H_
30 
31 
32 #include "rtxsrc/rtxDList.h"
33 
34 
48 typedef struct _OSRTStack {
49  struct OSCTXT* pctxt;
50  OSRTDList dlist;
51 } OSRTStack;
52 
53 #ifdef __cplusplus
54 extern "C" {
55 #endif
56 
65 EXTERNRT OSRTStack* rtxStackCreate (struct OSCTXT* pctxt);
66 
75 EXTERNRT void rtxStackInit (struct OSCTXT* pctxt, OSRTStack* pStack);
76 
82 #define rtxStackIsEmpty(stack) (OSBOOL)((stack).dlist.count == 0)
83 
92 EXTERNRT void* rtxStackPop (OSRTStack* pStack);
93 
105 EXTERNRT int rtxStackPush (OSRTStack* pStack, void* pData);
106 
118 EXTERNRT void* rtxStackPeek (OSRTStack* pStack);
119 
123 #ifdef __cplusplus
124 }
125 #endif
126 
127 #endif
int rtxStackPush(OSRTStack *pStack, void *pData)
Definition: rtxDList.h:64
void * rtxStackPop(OSRTStack *pStack)
OSRTStack * rtxStackCreate(struct OSCTXT *pctxt)
void * rtxStackPeek(OSRTStack *pStack)
Definition: rtxContext.h:198
Definition: rtxStack.h:48
void rtxStackInit(struct OSCTXT *pctxt, OSRTStack *pStack)