public class CborEncoder extends Object
Constructor and Description |
---|
CborEncoder(OutputStream outputStream)
Initialize a new encoder which writes the binary encoded data to an
OutputStream . |
public CborEncoder(OutputStream outputStream)
OutputStream
.public void encode(List<DataItem> dataItems) throws CborException
DataItem
s, also known as a stream.dataItems
- a list of DataItem
sCborException
- if the DataItem
s could not be encoded or there was an
problem with the OutputStream
.public void encode(DataItem dataItem) throws CborException
DataItem
.dataItem
- the DataItem
to encode. If null, encoder encodes a
SimpleValue
NULL value.CborException
- if DataItem
could not be encoded or there was an
problem with the OutputStream
.public void encode(RationalNumber rationalNumber) throws CborException
CborException
Copyright © 2014. All Rights Reserved.