summaryrefslogtreecommitdiffstats
path: root/policy-core/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'policy-core/src/main')
-rw-r--r--policy-core/src/main/java/org/onap/policy/drools/core/PolicySessionFeatureApi.java14
-rw-r--r--policy-core/src/main/java/org/onap/policy/drools/util/KieUtils.java11
2 files changed, 14 insertions, 11 deletions
diff --git a/policy-core/src/main/java/org/onap/policy/drools/core/PolicySessionFeatureApi.java b/policy-core/src/main/java/org/onap/policy/drools/core/PolicySessionFeatureApi.java
index 181fbe55..535b1d8b 100644
--- a/policy-core/src/main/java/org/onap/policy/drools/core/PolicySessionFeatureApi.java
+++ b/policy-core/src/main/java/org/onap/policy/drools/core/PolicySessionFeatureApi.java
@@ -2,7 +2,7 @@
* ============LICENSE_START=======================================================
* policy-core
* ================================================================================
- * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2017-2020 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -40,7 +40,8 @@ public interface PolicySessionFeatureApi extends OrderedService {
* @param args standard 'main' arguments, which are currently ignored
* @param configDir the relative directory containing configuration files
*/
- default void globalInit(String[] args, String configDir) {}
+ default void globalInit(String[] args, String configDir) {
+ }
/**
* This method is used to create a 'KieSession' as part of a
@@ -67,7 +68,8 @@ public interface PolicySessionFeatureApi extends OrderedService {
*
* @param policySession the new 'PolicySession' instance
*/
- default void newPolicySession(PolicySession policySession) {}
+ default void newPolicySession(PolicySession policySession) {
+ }
/**
* This method is called to select the 'ThreadModel' instance associated
@@ -98,7 +100,8 @@ public interface PolicySessionFeatureApi extends OrderedService {
* @param policySession the 'PolicySession' object that wrapped the
* 'KieSession'
*/
- default void disposeKieSession(PolicySession policySession) {}
+ default void disposeKieSession(PolicySession policySession) {
+ }
/**
* This method is called after 'KieSession.destroy()' is called.
@@ -106,5 +109,6 @@ public interface PolicySessionFeatureApi extends OrderedService {
* @param policySession the 'PolicySession' object that wrapped the
* 'KieSession'
*/
- default void destroyKieSession(PolicySession policySession) {}
+ default void destroyKieSession(PolicySession policySession) {
+ }
}
diff --git a/policy-core/src/main/java/org/onap/policy/drools/util/KieUtils.java b/policy-core/src/main/java/org/onap/policy/drools/util/KieUtils.java
index bd1c6cee..c260924b 100644
--- a/policy-core/src/main/java/org/onap/policy/drools/util/KieUtils.java
+++ b/policy-core/src/main/java/org/onap/policy/drools/util/KieUtils.java
@@ -2,7 +2,7 @@
* ============LICENSE_START=======================================================
* ONAP
* ================================================================================
- * Copyright (C) 2018-2019 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2018-2020 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -24,18 +24,17 @@ import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.net.URL;
-import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
-import java.nio.file.Path;
import java.util.ArrayList;
-import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.Enumeration;
import java.util.HashSet;
import java.util.List;
import java.util.stream.Collectors;
+
import lombok.NonNull;
+
import org.apache.commons.io.IOUtils;
import org.drools.compiler.kie.builder.impl.InternalKieModule;
import org.drools.compiler.kproject.models.KieModuleModelImpl;
@@ -74,7 +73,7 @@ public class KieUtils {
* Installs a rules artifact in the local maven repository.
*/
public static ReleaseId installArtifact(File kmodule, File pom, String drlKJarPath, @NonNull List<File> drls)
- throws IOException {
+ throws IOException {
KieModuleModel kieModule = KieModuleModelImpl.fromXML(kmodule);
final KieFileSystem kieFileSystem = KieServices.Factory.get().newKieFileSystem();
@@ -92,7 +91,7 @@ public class KieUtils {
* Installs a rules artifact in the local maven repository.
*/
public static ReleaseId installArtifact(File kmodule, File pom, String drlKJarPath, File drl)
- throws IOException {
+ throws IOException {
return installArtifact(kmodule, pom, drlKJarPath, Collections.singletonList(drl));
}