public static class BERTool.DecomposedBuilder extends java.lang.Object implements BERTool.DumpBuilder
Constructor and Description |
---|
DecomposedBuilder(java.io.PrintStream sink)
Constructs a new decomposed-TLV dump builder, which is used to dump
data from a specified byte buffer source to a specified
print stream sink.
|
Modifier and Type | Method and Description |
---|---|
void |
begin_dump()
Invoked when a BER encoding processing starts, before any
other method invocations.
|
void |
content(java.nio.ByteBuffer data)
Invoked when primitive contents octets are parsed.
|
void |
end_constructed()
Invoked when a constructed encoding ends.
|
void |
end_dump()
Invoked when a BER encoding processing ends, before returning
control to the caller.
|
void |
eoc(java.nio.ByteBuffer data)
Invoked when END-OF-CONTENTS octets are detected.
|
void |
error(java.nio.ByteBuffer data,
java.lang.String message)
Invoked when an error occurs.
|
int |
getTruncationLimit()
Gets the value of truncationLimit.
|
void |
length(java.nio.ByteBuffer data,
int length)
Invoked when a length is parsed.
|
BERTool.DecomposedBuilder |
setTruncationLimit(int truncationLimit)
Sets the value of truncationLimit.
|
void |
skip(java.nio.ByteBuffer data)
Invoked when a misencoded value is skipped.
|
void |
tag(java.nio.ByteBuffer data,
BERTool.Tag tag)
Invoked when a tag is parsed.
|
public DecomposedBuilder(java.io.PrintStream sink)
sink
- the value of sink.public int getTruncationLimit()
public BERTool.DecomposedBuilder setTruncationLimit(int truncationLimit)
truncationLimit
- the new value of truncationLimit.public void tag(java.nio.ByteBuffer data, BERTool.Tag tag)
BERTool.DumpBuilder
tag
in interface BERTool.DumpBuilder
data
- the ByteBuffer
object that contains BER bytes
that represent a tag encoding. The encoding is
delimited by the position
and limit
properties of the ByteBuffer
.tag
- the decoded tag.public void length(java.nio.ByteBuffer data, int length)
BERTool.DumpBuilder
length
in interface BERTool.DumpBuilder
data
- the ByteBuffer
object that contains BER bytes
that represent a length encoding. The encoding is
delimited by the position
and limit
properties of the ByteBuffer
.length
- the decoded length or -1 for indefinite length encodings.public void eoc(java.nio.ByteBuffer data)
BERTool.DumpBuilder
eoc
in interface BERTool.DumpBuilder
data
- the ByteBuffer
object that contains BER bytes
that represent the EOC. The EOC bytes are
delimited by the position
and limit
properties of the ByteBuffer
.public void content(java.nio.ByteBuffer data)
BERTool.DumpBuilder
content
in interface BERTool.DumpBuilder
data
- the ByteBuffer
object that contains BER bytes
that represent primitive content octets. The primitive
contents octets are delimited by the position
and
limit
properties of the ByteBuffer
.public void skip(java.nio.ByteBuffer data)
BERTool.DumpBuilder
skip
in interface BERTool.DumpBuilder
data
- the ByteBuffer
object that contains BER bytes
that are skipped. The bytes are delimited by the
position
and limit
properties of
the ByteBuffer
.public void error(java.nio.ByteBuffer data, java.lang.String message)
BERTool.DumpBuilder
error
in interface BERTool.DumpBuilder
data
- the ByteBuffer
object that contains erroneous
BER data. The position
property specifies
the position of the error in the encoded data.message
- the error message.public void end_constructed()
BERTool.DumpBuilder
end_constructed
in interface BERTool.DumpBuilder
public void begin_dump()
BERTool.DumpBuilder
begin_dump
in interface BERTool.DumpBuilder
public void end_dump()
BERTool.DumpBuilder
end_dump
in interface BERTool.DumpBuilder
Copyright © 2020 OSS Nokalva, Inc. All rights reserved.
This document is proprietary to OSS Nokalva, Inc., and may be used only by their direct licensees. Distribution is not permitted. This copyright statement must not be removed.