ASN1C C# Runtime Library  7.4
Public Member Functions | List of all members
Asn1PerBitFieldPrinter Class Reference

Public Member Functions

 Asn1PerBitFieldPrinter (Asn1PerMessageBuffer perMessageBuffer, System.IO.Stream encodedMessage)
 
virtual void Print (System.IO.StreamWriter outs, System.String varName)
 

Detailed Description

This class is used to obtain a formatted printout of the bit fields that make up a PER encoded message.

Constructor & Destructor Documentation

◆ Asn1PerBitFieldPrinter()

Asn1PerBitFieldPrinter ( Asn1PerMessageBuffer  perMessageBuffer,
System.IO.Stream  encodedMessage 
)

Constructor

Parameters
perMessageBufferPER encode or decode message buffer
encodedMessageInput stream of encoded message

Member Function Documentation

◆ Print()

virtual void Print ( System.IO.StreamWriter  outs,
System.String  varName 
)
virtual

This method iterates through and prints all of the bit fields in a PER encoded message. Bit tracing needs to have been enabled in the buffer via the 'perTraceEnable' method prior to encoding or decoding the message.

Parameters
outsPrint stream
varNameVariable name. This will be printed before all fields (for example, <varName> .field1, etc.)

References Asn1PerBitField.BitCount, Asn1PerTraceHandler.BitFieldList, Asn1PerBitField.BitOffset, Asn1PerBitFieldList.Iterator(), Asn1PerBitField.Name, Diag.Prtln(), StringBufferExt.Replace(), Asn1Util.ToHexString(), and Asn1PerMessageBuffer.TraceHandler.

Referenced by Asn1PerEncodeTraceHandler.Print(), Asn1PerOutputStreamTraceHandler.Print(), and Asn1PerDecodeTraceHandler.Print().