Objective Systems, Inc.  
Home
About ASN.1
Products
Free Software
Documents
Services
Resources
Resellers
Customers
Careers
About Us
Contact Us
 

Google


Objective Systems, Inc.

ASN1TPDU Struct Reference
[ASN.1 Type (ASN1T_) Base Classes]

#include <asn1CppTypes.h>

Inheritance diagram for ASN1TPDU:

ASN1TPDUSeqOfList List of all members.

Detailed Description

Base class for PDU types. This class is used as the base class for all compiler-generated PDU types.


Public Member Functions

void setContext (ASN1Context *ctxt)

Protected Attributes

ASN1CtxtPtr mpContext


Member Function Documentation

void ASN1TPDU::setContext ASN1Context ctxt  )  [inline]
 

The setContext method allows the context member variable to be set. It is invoked in compiler-generated control class decode and copy methods. This method is invoked to prevent memory freeing of decoded or copied data after control class or message buffer object goes out of scope. Also, if context is set to ASN1TPDU then generated destuctor of inherited ASN1T_<type> class will invoke generated free routines. Note, it is not obligatory to call generated free routines unless series of messages being decoded or control class and message buffer objects go out of scope somewhere. The destructor of the control class or message buffer class will free all dynamicly allocated memory. Thus, if performance is a main issue, "setContext (NULL)" may be called after Decode method call. In this case destructor of ASN1T_<type> will do nothing.

Parameters:
ctxt A pointer to reference counted ASN.1 context class instance.


Member Data Documentation

ASN1CtxtPtr ASN1TPDU::mpContext [protected]
 

The mpContext member variable holds a smart-pointer to the current context variable. This ensures an instance of this PDU type will persist if the control class and message buffer classes used to decode or copy the message are destroyed.


The documentation for this struct was generated from the following file:

Copyright © 1997-2004 Objective Systems,Inc.
All Rights Reserved.
This document may be distributed in any form, electronic
or otherwise, provided that it is distributed in its entirety
and that the copyright and this notice are included.

This file was last modified on 1 Oct 2004.
ASN1C C/C++ Common Runtime, ASN1C v5.7x