svn commit: r1869181 - /ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1869181 - /ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java

mthl
Author: mthl
Date: Wed Oct 30 15:34:30 2019
New Revision: 1869181

URL: http://svn.apache.org/viewvc?rev=1869181&view=rev
Log:
Improved: Remove unnecessary ‘throws’ declarations
(OFBIZ-11264)

Some declared and/or documented exceptions that were not actually
thrown.

Modified:
    ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java

Modified: ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java?rev=1869181&r1=1869180&r2=1869181&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java (original)
+++ ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/container/ComponentContainer.java Wed Oct 30 15:34:30 2019
@@ -119,8 +119,7 @@ public class ComponentContainer implemen
      * @throws IOException when component directory loading fails.
      * @throws ComponentException when retrieving component configuration files fails.
      */
-    private void loadComponent(Path dir, ComponentDef component)
-            throws IOException, ComponentException {
+    private void loadComponent(Path dir, ComponentDef component) throws IOException, ComponentException {
         Path location = component.location.isAbsolute() ? component.location : dir.resolve(component.location);
         switch (component.type) {
         case COMPONENT_DIRECTORY:
@@ -141,7 +140,6 @@ public class ComponentContainer implemen
      *
      * @param directoryName the name of component directory to load
      * @throws IOException
-     * @throws ContainerException
      * @throws ComponentException
      */
     private void loadComponentDirectory(Path directoryName) throws IOException, ComponentException {
@@ -168,7 +166,6 @@ public class ComponentContainer implemen
      * @param directoryPath the absolute path of the directory
      * @param componentLoadFile the name of the load file (i.e. component-load.xml)
      * @throws IOException
-     * @throws ContainerException
      */
     private void loadComponentsInDirectoryUsingLoadFile(Path directoryPath, Path componentLoadFile) throws IOException {
         URL configUrl = null;
@@ -277,10 +274,9 @@ public class ComponentContainer implemen
      * the list of classpaths to be loaded
      *
      * @param config the component configuration
-     * @throws IOException
      * @throws ComponentException
      */
-    private void loadSingleComponent(ComponentConfig config) throws IOException, ComponentException {
+    private void loadSingleComponent(ComponentConfig config) throws ComponentException {
         if (config.enabled()) {
             List<DependsOnInfo> dependencyList = checkDependencyForComponent(config);
             if (UtilValidate.isEmpty(dependencyList)) {
@@ -297,11 +293,9 @@ public class ComponentContainer implemen
      * from list of unloaded components
      *
      * @param config the component configuration
-     * @throws IOException
      * @throws ComponentException
-     *
      */
-    private List<DependsOnInfo> checkDependencyForComponent(ComponentConfig config) throws IOException, ComponentException {
+    private List<DependsOnInfo> checkDependencyForComponent(ComponentConfig config) throws ComponentException {
         List<DependsOnInfo> dependencyList = new ArrayList<>(config.getDependsOn());
         if (UtilValidate.isNotEmpty(dependencyList)) {
             Set<DependsOnInfo> resolvedDependencyList = new HashSet<>();