Class DataBlock
- Namespace
- TechnologySolutions.Rfid.AsciiProtocol
- Assembly
- TechnologySolutions.Rfid.AsciiProtocol.Core.dll
Represents a block of binary data (byte array)
public class DataBlock
- Inheritance
-
DataBlock
- Inherited Members
Constructors
DataBlock(byte[])
Initializes a new instance of the DataBlock class
public DataBlock(byte[] data)
Parameters
data
byte[]The data of the DataBlock
DataBlock(byte[], int, int)
Initializes a new instance of the DataBlock class
public DataBlock(byte[] data, int offset, int length)
Parameters
data
byte[]The array to copy the data from
offset
intThe offset into the array to start from
length
intThe number of bytes to copy
DataBlock(string)
Initializes a new instance of the DataBlock class
public DataBlock(string hex)
Parameters
hex
stringThe data represented as a hex string
Properties
Base16
Gets the DataBlock as a Base16 (hex) string
public string Base16 { get; }
Property Value
LengthBits
Gets the length of the data block in bits
public int LengthBits { get; }
Property Value
LengthBytes
Gets the length of the data block in bytes
public int LengthBytes { get; }
Property Value
LengthWords
Gets the length of the data block in words
public int LengthWords { get; }
Property Value
Methods
ToArray()
Returns the value of the DataBlock as a byte array
public byte[] ToArray()
Returns
- byte[]
The value of the DataBlock as a byte array