mirror of
https://codeberg.org/PGPainless/cert-d-java.git
synced 2024-06-15 16:14:55 +02:00
33 lines
746 B
Java
33 lines
746 B
Java
|
// SPDX-FileCopyrightText: 2022 Paul Schaub <vanitasvitae@fsfe.org>
|
||
|
//
|
||
|
// SPDX-License-Identifier: Apache-2.0
|
||
|
|
||
|
package pgp.certificate_store;
|
||
|
|
||
|
import java.io.IOException;
|
||
|
import java.io.InputStream;
|
||
|
|
||
|
/**
|
||
|
* OpenPGP key (secret key).
|
||
|
*/
|
||
|
public abstract class Key {
|
||
|
|
||
|
/**
|
||
|
* Return the certificate part of this OpenPGP key.
|
||
|
*
|
||
|
* @return OpenPGP certificate
|
||
|
*/
|
||
|
public abstract Certificate getCertificate();
|
||
|
|
||
|
/**
|
||
|
* Return an {@link InputStream} of the binary representation of the secret key.
|
||
|
*
|
||
|
* @return input stream
|
||
|
* @throws IOException in case of an IO error
|
||
|
*/
|
||
|
public abstract InputStream getInputStream() throws IOException;
|
||
|
|
||
|
public abstract String getTag() throws IOException;
|
||
|
|
||
|
}
|