public class OpenPGPKeyReader
extends java.lang.Object
OpenPGPKeys
or OpenPGPCertificates
.Constructor and Description |
---|
OpenPGPKeyReader() |
OpenPGPKeyReader(OpenPGPImplementation implementation) |
OpenPGPKeyReader(OpenPGPImplementation implementation,
OpenPGPPolicy policy) |
Modifier and Type | Method and Description |
---|---|
OpenPGPCertificate |
parseCertificate(byte[] bytes)
Parse a single
OpenPGPCertificate from bytes. |
OpenPGPCertificate |
parseCertificate(java.io.InputStream inputStream)
Parse a single
OpenPGPCertificate from an InputStream . |
OpenPGPCertificate |
parseCertificate(java.lang.String armored)
Parse a single
OpenPGPCertificate from an ASCII armored string. |
OpenPGPCertificate |
parseCertificateOrKey(byte[] bytes)
Parse a single
OpenPGPCertificate or OpenPGPKey from bytes. |
OpenPGPCertificate |
parseCertificateOrKey(java.io.InputStream inputStream)
|
OpenPGPCertificate |
parseCertificateOrKey(java.lang.String armored)
Parse a single
OpenPGPCertificate or OpenPGPKey from an ASCII armored string. |
java.util.List<OpenPGPCertificate> |
parseCertificates(byte[] bytes) |
java.util.List<OpenPGPCertificate> |
parseCertificates(java.io.InputStream inputStream) |
java.util.List<OpenPGPCertificate> |
parseCertificates(java.lang.String armored) |
OpenPGPKey |
parseKey(byte[] bytes)
Parse an
OpenPGPKey from bytes. |
OpenPGPKey |
parseKey(java.io.InputStream inputStream)
Parse an
OpenPGPKey from an InputStream |
OpenPGPKey |
parseKey(java.lang.String armored)
Parse an
OpenPGPKey from an ASCII armored string. |
java.util.List<OpenPGPKey> |
parseKeys(byte[] bytes) |
java.util.List<OpenPGPKey> |
parseKeys(java.io.InputStream inputStream) |
java.util.List<OpenPGPKey> |
parseKeys(java.lang.String armored) |
java.util.List<OpenPGPCertificate> |
parseKeysOrCertificates(byte[] bytes) |
java.util.List<OpenPGPCertificate> |
parseKeysOrCertificates(java.io.InputStream inputStream) |
java.util.List<OpenPGPCertificate> |
parseKeysOrCertificates(java.lang.String armored) |
public OpenPGPKeyReader()
public OpenPGPKeyReader(OpenPGPImplementation implementation)
public OpenPGPKeyReader(OpenPGPImplementation implementation, OpenPGPPolicy policy)
public OpenPGPCertificate parseCertificate(java.lang.String armored) throws java.io.IOException
OpenPGPCertificate
from an ASCII armored string.armored
- ASCII armored stringjava.io.IOException
- if the parsed object is a secret key or if the cert cannot be parsedpublic OpenPGPCertificate parseCertificate(java.io.InputStream inputStream) throws java.io.IOException
OpenPGPCertificate
from an InputStream
.inputStream
- ASCII armored or binary input streamjava.io.IOException
- if the parsed object is a secret key or if the cert cannot be parsedpublic OpenPGPCertificate parseCertificate(byte[] bytes) throws java.io.IOException
OpenPGPCertificate
from bytes.bytes
- ASCII armored or binary bytesjava.io.IOException
- if the parsed object is a secret key or if the cert cannot be parsedpublic OpenPGPCertificate parseCertificateOrKey(java.lang.String armored) throws java.io.IOException
OpenPGPCertificate
or OpenPGPKey
from an ASCII armored string.armored
- ASCII armored stringjava.io.IOException
- if the key or certificate cannot be parsedpublic OpenPGPCertificate parseCertificateOrKey(java.io.InputStream inputStream) throws java.io.IOException
inputStream
- input stream containing the ASCII armored or binary key or certificatejava.io.IOException
- if the key or certificate cannot be parsedpublic OpenPGPCertificate parseCertificateOrKey(byte[] bytes) throws java.io.IOException
OpenPGPCertificate
or OpenPGPKey
from bytes.bytes
- ASCII armored or binary key or certificatejava.io.IOException
- if the key or certificate cannot be parsedpublic OpenPGPKey parseKey(java.lang.String armored) throws java.io.IOException
OpenPGPKey
from an ASCII armored string.armored
- ASCII armored stringjava.io.IOException
- if the key cannot be parsed.public OpenPGPKey parseKey(java.io.InputStream inputStream) throws java.io.IOException
OpenPGPKey
from an InputStream
inputStream
- containing the ASCII armored or binary keyjava.io.IOException
- if the key cannot be parsed.public OpenPGPKey parseKey(byte[] bytes) throws java.io.IOException
OpenPGPKey
from bytes.bytes
- ASCII armored or binary keyjava.io.IOException
- if the key cannot be parsed.public java.util.List<OpenPGPCertificate> parseKeysOrCertificates(java.lang.String armored) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPCertificate> parseKeysOrCertificates(java.io.InputStream inputStream) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPCertificate> parseKeysOrCertificates(byte[] bytes) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPCertificate> parseCertificates(java.lang.String armored) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPCertificate> parseCertificates(java.io.InputStream inputStream) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPCertificate> parseCertificates(byte[] bytes) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPKey> parseKeys(java.lang.String armored) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPKey> parseKeys(java.io.InputStream inputStream) throws java.io.IOException
java.io.IOException
public java.util.List<OpenPGPKey> parseKeys(byte[] bytes) throws java.io.IOException
java.io.IOException