Organize cert-d-java classes in packages

This commit is contained in:
Paul Schaub 2022-08-11 21:50:02 +02:00
parent 7cc0ef5037
commit f91c5065fc
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311
19 changed files with 56 additions and 10 deletions

View file

@ -11,7 +11,7 @@ import java.util.HashSet;
import java.util.List;
import java.util.Set;
import pgp.cert_d.SubkeyLookup;
import pgp.cert_d.subkey_lookup.SubkeyLookup;
public class DatabaseSubkeyLookup implements SubkeyLookup {

View file

@ -3,6 +3,6 @@
// SPDX-License-Identifier: Apache-2.0
/**
* Implementation of a {@link pgp.cert_d.SubkeyLookup} mechanism using an SQLite Database.
* Implementation of a {@link pgp.cert_d.subkey_lookup.SubkeyLookup} mechanism using an SQLite Database.
*/
package pgp.cert_d.jdbc.sqlite;

View file

@ -4,6 +4,9 @@
package pgp.cert_d;
import pgp.cert_d.backend.FileBasedCertificateDirectoryBackend;
import pgp.cert_d.backend.InMemoryCertificateDirectoryBackend;
import pgp.cert_d.exception.NotAStoreException;
import pgp.certificate.KeyMaterialReaderBackend;
import java.io.File;

View file

@ -4,6 +4,8 @@
package pgp.cert_d;
import pgp.cert_d.exception.BadDataException;
import pgp.cert_d.exception.BadNameException;
import pgp.certificate.Certificate;
import pgp.certificate.KeyMaterial;
import pgp.certificate.KeyMaterialMerger;

View file

@ -4,6 +4,8 @@
package pgp.cert_d;
import pgp.cert_d.exception.BadDataException;
import pgp.cert_d.exception.BadNameException;
import pgp.certificate.Certificate;
import java.io.IOException;

View file

@ -4,6 +4,8 @@
package pgp.cert_d;
import pgp.cert_d.exception.BadDataException;
import pgp.cert_d.exception.BadNameException;
import pgp.certificate.Certificate;
import pgp.certificate.KeyMaterial;
import pgp.certificate.KeyMaterialMerger;

View file

@ -2,8 +2,13 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.backend;
import pgp.cert_d.PGPCertificateDirectory;
import pgp.cert_d.SpecialNames;
import pgp.cert_d.exception.BadDataException;
import pgp.cert_d.exception.BadNameException;
import pgp.cert_d.exception.NotAStoreException;
import pgp.certificate.Certificate;
import pgp.certificate.KeyMaterial;
import pgp.certificate.KeyMaterialMerger;

View file

@ -2,8 +2,12 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.backend;
import pgp.cert_d.PGPCertificateDirectory;
import pgp.cert_d.SpecialNames;
import pgp.cert_d.exception.BadDataException;
import pgp.cert_d.exception.BadNameException;
import pgp.certificate.Certificate;
import pgp.certificate.KeyMaterial;
import pgp.certificate.KeyMaterialMerger;

View file

@ -0,0 +1,8 @@
// SPDX-FileCopyrightText: 2022 Paul Schaub <vanitasvitae@fsfe.org>
//
// SPDX-License-Identifier: Apache-2.0
/**
* Storage Backends.
*/
package pgp.cert_d.backend;

View file

@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.exception;
/**
* The data was not a valid OpenPGP cert or key in binary format.

View file

@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.exception;
/**
* Provided name was neither a valid fingerprint, nor a known special name.

View file

@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.exception;
/**
* The base dir cannot possibly contain a store.

View file

@ -0,0 +1,8 @@
// SPDX-FileCopyrightText: 2022 Paul Schaub <vanitasvitae@fsfe.org>
//
// SPDX-License-Identifier: Apache-2.0
/**
* Exceptions.
*/
package pgp.cert_d.exception;

View file

@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.subkey_lookup;
import java.util.Collections;
import java.util.HashMap;

View file

@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: Apache-2.0
package pgp.cert_d;
package pgp.cert_d.subkey_lookup;
import java.io.IOException;
import java.util.List;

View file

@ -0,0 +1,8 @@
// SPDX-FileCopyrightText: 2022 Paul Schaub <vanitasvitae@fsfe.org>
//
// SPDX-License-Identifier: Apache-2.0
/**
* Subkey Lookup functionality.
*/
package pgp.cert_d.subkey_lookup;

View file

@ -4,7 +4,7 @@
package pgp.certificate;
import pgp.cert_d.BadDataException;
import pgp.cert_d.exception.BadDataException;
import java.io.IOException;
import java.io.InputStream;

View file

@ -6,6 +6,8 @@ package pgp.cert_d;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import pgp.cert_d.backend.FileBasedCertificateDirectoryBackend;
import pgp.cert_d.exception.BadNameException;
import java.io.File;
import java.io.IOException;

View file

@ -24,6 +24,8 @@ import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.MethodSource;
import pgp.cert_d.jdbc.sqlite.DatabaseSubkeyLookup;
import pgp.cert_d.jdbc.sqlite.SqliteSubkeyLookupDaoImpl;
import pgp.cert_d.subkey_lookup.InMemorySubkeyLookup;
import pgp.cert_d.subkey_lookup.SubkeyLookup;
public class SubkeyLookupTest {