FormattedValue class

Holds a value alongside the format it is encoded with.

Constructors

FormattedValue({required KeyFormat format, required Object value, String? pemLabel})
const

Properties

format KeyFormat
The declared format of value.
final
hashCode int
The hash code for this object.
no setterinherited
pemLabel String?
The PEM label to use when emitting PEM (e.g. PUBLIC KEY).
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value Object
Either a String or Uint8List holding the formatted bytes.
final

Methods

asString() String?
Returns the formatted value as a string if already string-backed.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toBase64() String
Returns the contents encoded as base64.
toBytes() Uint8List
Returns the underlying bytes, decoding when necessary.
toHex({bool uppercase = false}) String
Returns the contents encoded as hexadecimal.
toPem({String? overrideLabel}) String
Returns the contents encoded as a PEM block.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited