diff options
author | Tomasz Wrobel <tomasz.wrobel@nokia.com> | 2020-06-16 15:36:23 +0200 |
---|---|---|
committer | Tomasz Wrobel <tomasz.wrobel@nokia.com> | 2020-06-16 15:36:23 +0200 |
commit | fc666727897c9f78fdcddbf4b678e1c0b0c413a9 (patch) | |
tree | 98a6971859d37e63813369d48a7449f08e4108bc /certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion | |
parent | b288b7ab24f33af72e9c0fedecbb9979d1b4afc7 (diff) |
Remove unnecessary exceptions
Issue-ID: AAF-1152
Signed-off-by: Tomasz Wrobel <tomasz.wrobel@nokia.com>
Change-Id: Ie343cd2e3006f9217db5b8454c060eb8c1d3e9e3
Diffstat (limited to 'certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion')
-rw-r--r-- | certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion/ArtifactsCreatorProvider.java | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion/ArtifactsCreatorProvider.java b/certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion/ArtifactsCreatorProvider.java index 6fbf373b..ac1eda1a 100644 --- a/certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion/ArtifactsCreatorProvider.java +++ b/certServiceClient/src/main/java/org/onap/aaf/certservice/client/certification/conversion/ArtifactsCreatorProvider.java @@ -18,12 +18,6 @@ */ package org.onap.aaf.certservice.client.certification.conversion; -import org.onap.aaf.certservice.client.certification.exception.CertOutputTypeNotSupportedException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -import java.util.Arrays; - public enum ArtifactsCreatorProvider { P12 { @@ -48,18 +42,8 @@ public enum ArtifactsCreatorProvider { } }; - private static final Logger LOGGER = LoggerFactory.getLogger(ArtifactsCreatorProvider.class); - - public static ArtifactsCreator getCreator(String outputType, String outputPath) - throws CertOutputTypeNotSupportedException { - try { - LOGGER.info("Artifact creation type selected: {}", outputType); + public static ArtifactsCreator getCreator(String outputType, String outputPath) { return valueOf(outputType).create(outputPath); - } catch (IllegalArgumentException e) { - LOGGER.error("Artifact creation type: {} is not supported. Supported types: {}", - outputType, Arrays.toString(values())); - throw new CertOutputTypeNotSupportedException(e); - } } abstract ArtifactsCreator create(String outputPath); |