11#ifndef __BE_DEVICE_TLV_H__
12#define __BE_DEVICE_TLV_H__
83 TLV(
const std::string &filename);
184 std::shared_ptr<TLV::Impl> pimpl;
A class to represent a Tag-Length-Value (TLV) data structure as described in the ISO 7816-4 integrate...
Memory::uint8Array getRawTLV() const
Obtain the TLV as an array of 8-bit values.
std::vector< TLV > getChildren() const
Get copies of the child TLVs.
void addChild(const TLV &tlv)
Add a child TLV.
bool isPrimitive() const
Obtain the type of TLV: primitive/constructed.
uint32_t getTagNum() const
Get the decoded tag number.
TLV()
Construct an empty Tag-Length-Value object that can be filled with setter methods.
uint8_t getTagClass() const
Get the decoded tag class.
TLV(const Memory::uint8Array &buf)
Construct a Tag-Length-Value object from the given buffer.
void setTag(const Memory::uint8Array &tag)
Set the encoded tag value.
void setPrimitive(const Memory::uint8Array &value)
Set the primitive data associated with this TLV.
TLV(const std::string &filename)
Construct a Tag-Length-Value object from the given file name.
static std::string stringFromTLV(const TLV &tlv, const int tabCount)
Class utility function to print the contents of a TLV into a string object, in readable format.
const Memory::uint8Array getTag() const
Obtain the encoded tag value.
TLV(Memory::IndexedBuffer &ibuf)
Construct a single TLV from the indexed buffer.
Memory::uint8Array getPrimitive() const
Obtain the primitive data associated with this TLV.
Wrap a memory buffer with an index.
This software was developed at the National Institute of Standards and Technology (NIST) by employees...