View Source OpenPGP.Packet.Behaviour behaviour (OpenPGP v0.6.2)
All packet specific decoders must implement
OpenPGP.Packet.Behaviour
, which exposes .decode/1
interface
(including genric OpenPGP.Packet
). Additionaly some of the packet
specific decoders may provide interface for further packet processing,
such as OpenPGP.SecretKeyPacket.decrypt/2
.
Summary
Callbacks
This callback is widely used to provide a clear interface to decoding OpenPGP packets. All tag-specific packets implement this callback: accepting a binary input and returning a two element tuple with a decoded packet and a remainder of an input binary.
Callbacks
@callback decode(binary()) :: {OpenPGP.any_packet(), binary()}
This callback is widely used to provide a clear interface to decoding OpenPGP packets. All tag-specific packets implement this callback: accepting a binary input and returning a two element tuple with a decoded packet and a remainder of an input binary.