Clean up public interfaces
authorRyan Goulding <ryandgoulding@gmail.com>
Thu, 14 Sep 2017 16:14:12 +0000 (12:14 -0400)
committerRyan Goulding <ryandgoulding@gmail.com>
Thu, 14 Sep 2017 16:24:23 +0000 (12:24 -0400)
The Java programming language assigns certain defaults for methods
and constants defined in interfaces.  This change removes the
unnecessary redundant modifiers appropriately.

For example:
* interface methods are public by default
* interface constants are public by default
* interface methods are abstract unless "default" is specifically
  used (as of JDK8+).

This is really just to get rid of annoying warnings present in
IDE(s).

Issue-Id: SDNC-79
Change-Id: I2e6b3e4fa02bad1beee2cbb49d3766722eff1ba0
Signed-off-by: Ryan Goulding <ryandgoulding@gmail.com>
dblib/provider/src/main/java/org/onap/ccsdk/sli/core/dblib/DBResourceObserver.java
dblib/provider/src/main/java/org/onap/ccsdk/sli/core/dblib/DataAccessor.java
dblib/provider/src/main/java/org/onap/ccsdk/sli/core/dblib/DataSourceComparator.java
dblib/provider/src/main/java/org/onap/ccsdk/sli/core/dblib/DbLibService.java
dblib/provider/src/main/java/org/onap/ccsdk/sli/core/dblib/pm/SQLExecutionMonitorObserver.java
sli/provider/src/main/java/org/onap/ccsdk/sli/core/sli/provider/SvcLogicService.java
sliPluginUtils/provider/src/main/java/org/onap/ccsdk/sli/core/slipluginutils/SvcLogicContextObject.java

index 2e1a6e9..f30212d 100644 (file)
@@ -23,5 +23,5 @@ package org.onap.ccsdk.sli.core.dblib;
 import java.util.Observer;
 
 public interface DBResourceObserver extends Observer {
-       public boolean isMonitorDbResponse();
+    boolean isMonitorDbResponse();
 }
index 7921fa5..fdfb47b 100644 (file)
@@ -27,7 +27,7 @@ import javax.sql.rowset.CachedRowSet;
 
 public interface DataAccessor {
 
-       public abstract CachedRowSet getData(String statement, ArrayList<String> arguments, String preferredDS)
-                       throws SQLException;
+    CachedRowSet getData(String statement, ArrayList<String> arguments, String preferredDS)
+            throws SQLException;
 
 }
index bc14fb8..4cfcc73 100644 (file)
@@ -24,10 +24,10 @@ import java.util.Comparator;
 
 public interface DataSourceComparator extends Comparator <CachedDataSource>{
 
-       public abstract CachedDataSource getLastUsed();
+    CachedDataSource getLastUsed();
 
-       public abstract void setLastUsed(CachedDataSource lastUsed);
+    void setLastUsed(CachedDataSource lastUsed);
 
-       public abstract int compare(CachedDataSource ds1, CachedDataSource ds2);
+    int compare(CachedDataSource ds1, CachedDataSource ds2);
 
 }
index 0dea664..b31de35 100644 (file)
@@ -28,22 +28,22 @@ import javax.sql.rowset.CachedRowSet;
 
 public interface DbLibService {
 
-       /* (non-Javadoc)
-        * @see DataAccessor#getData(java.lang.String, java.util.ArrayList)
-        */
-       public abstract CachedRowSet getData(String statement,
-                       ArrayList<String> arguments, String preferredDS)
-                       throws SQLException;
-
-       /* (non-Javadoc)
-        * @see DataAccessor#writeData(java.lang.String, java.util.ArrayList)
-        */
-       public abstract boolean writeData(String statement,
-                       ArrayList<String> arguments, String preferredDS)
-                       throws SQLException;
-
-       public abstract boolean isActive();
-
-       public abstract Connection getConnection() throws SQLException;
+    /* (non-Javadoc)
+     * @see DataAccessor#getData(java.lang.String, java.util.ArrayList)
+     */
+    CachedRowSet getData(String statement,
+            ArrayList<String> arguments, String preferredDS)
+            throws SQLException;
+
+    /* (non-Javadoc)
+     * @see DataAccessor#writeData(java.lang.String, java.util.ArrayList)
+     */
+    boolean writeData(String statement,
+            ArrayList<String> arguments, String preferredDS)
+            throws SQLException;
+
+    boolean isActive();
+
+    Connection getConnection() throws SQLException;
 
 }
index c17696a..2fdde1e 100644 (file)
 package org.onap.ccsdk.sli.core.dblib.pm;
 
 public interface SQLExecutionMonitorObserver {
-       public String getDbConnectionName();
+    String getDbConnectionName();
 
-       public long getInterval();
-       public void setInterval(long value);
+    long getInterval();
+    void setInterval(long value);
 
-       public long getInitialDelay();
-       public void setInitialDelay(long value);
+    long getInitialDelay();
+    void setInitialDelay(long value);
 
-       public long getExpectedCompletionTime();
-       public void setExpectedCompletionTime(long value);
+    long getExpectedCompletionTime();
+    void setExpectedCompletionTime(long value);
 
-       public long getUnprocessedFailoverThreshold();
-       public void setUnprocessedFailoverThreshold(long value);
+    long getUnprocessedFailoverThreshold();
+    void setUnprocessedFailoverThreshold(long value);
 }
index 23911b6..19d985d 100644 (file)
@@ -28,49 +28,49 @@ import org.opendaylight.controller.md.sal.dom.api.DOMDataBroker;
 
 public interface SvcLogicService {
 
-       public static final String NAME = "org.onap.ccsdk.sli.core.sli.provider.SvcLogicService";
+    String NAME = "org.onap.ccsdk.sli.core.sli.provider.SvcLogicService";
 
-       // public SvcLogicContext execute(SvcLogicGraph graph, SvcLogicContext ctx) throws SvcLogicException;
-       /**
-        * Check for existence of a directed graph
-        * @param module - module name
-        * @param rpc - rpc name
-        * @param version - version.  If null, looks for active version
-        * @param mode - mode (sync/async)
-        * @return true if directed graph found, false otherwise
-        * @throws SvcLogicException
-        */
-       public boolean hasGraph(String module, String rpc, String version, String mode) throws SvcLogicException;
+    // public SvcLogicContext execute(SvcLogicGraph graph, SvcLogicContext ctx) throws SvcLogicException;
+    /**
+     * Check for existence of a directed graph
+     * @param module - module name
+     * @param rpc - rpc name
+     * @param version - version.  If null, looks for active version
+     * @param mode - mode (sync/async)
+     * @return true if directed graph found, false otherwise
+     * @throws SvcLogicException
+     */
+    boolean hasGraph(String module, String rpc, String version, String mode) throws SvcLogicException;
 
-       /**
-        *  Execute a directed graph
-        *
-        * @param module - module name
-        * @param rpc - rpc name
-        * @param version - version.  If null, use active version
-        * @param mode - mode (sync/async)
-        * @param parms - parameters, used to set SvcLogicContext attributes
-        * @return final values of attributes from SvcLogicContext, as Properties
-        * @throws SvcLogicException
-        *
-        *
-        *  @deprecated use execute(String module, String rpc, String version, String mode, DOMDataBroker dataBroker) instead
-        */
-       @Deprecated
-       public Properties execute(String module, String rpc, String version, String mode, Properties parms) throws SvcLogicException;
+    /**
+     *  Execute a directed graph
+     *
+     * @param module - module name
+     * @param rpc - rpc name
+     * @param version - version.  If null, use active version
+     * @param mode - mode (sync/async)
+     * @param parms - parameters, used to set SvcLogicContext attributes
+     * @return final values of attributes from SvcLogicContext, as Properties
+     * @throws SvcLogicException
+     *
+     *
+     *  @deprecated use execute(String module, String rpc, String version, String mode, DOMDataBroker dataBroker) instead
+     */
+    @Deprecated
+    Properties execute(String module, String rpc, String version, String mode, Properties parms) throws SvcLogicException;
 
-       /**
-        * Execute a directed graph
-        *
-        * @param module - module name
-        * @param rpc - rpc name
-        * @param version - version.  If null, use active version
-        * @param mode - mode (sync/async)
-        * @param parms - parameters, used to set SvcLogicContext attributes
-        * @param domDataBroker - DOMDataBroker object
-        * @return final values of attributes from SvcLogicContext, as Properties
-        * @throws SvcLogicException
-        */
-       public Properties execute(String module, String rpc, String version, String mode, Properties parms, DOMDataBroker domDataBroker) throws SvcLogicException;
+    /**
+     * Execute a directed graph
+     *
+     * @param module - module name
+     * @param rpc - rpc name
+     * @param version - version.  If null, use active version
+     * @param mode - mode (sync/async)
+     * @param parms - parameters, used to set SvcLogicContext attributes
+     * @param domDataBroker - DOMDataBroker object
+     * @return final values of attributes from SvcLogicContext, as Properties
+     * @throws SvcLogicException
+     */
+    Properties execute(String module, String rpc, String version, String mode, Properties parms, DOMDataBroker domDataBroker) throws SvcLogicException;
 
 }
index eaa92c3..aa41a5c 100644 (file)
@@ -24,5 +24,5 @@ package org.onap.ccsdk.sli.core.slipluginutils;
 import org.onap.ccsdk.sli.core.sli.SvcLogicContext;
 
 public interface SvcLogicContextObject {
-       public void writeToContext( SvcLogicContext ctx, String root );
+    void writeToContext(SvcLogicContext ctx, String root );
 }