You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2016/06/07 00:50:15 UTC
svn commit: r1747104 - in /commons/proper/chain/trunk:
api/src/main/java/org/apache/commons/chain2/
apps/example2/src/main/java/org/apache/commons/chain2/apps/example/
base/src/main/java/org/apache/commons/chain2/base/
base/src/main/java/org/apache/com...
Author: ggregory
Date: Tue Jun 7 00:50:15 2016
New Revision: 1747104
URL: http://svn.apache.org/viewvc?rev=1747104&view=rev
Log:
Update old school @exception with new school @throws.
Modified:
commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Chain.java
commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Command.java
commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Filter.java
commons/proper/chain/trunk/apps/example2/src/main/java/org/apache/commons/chain2/apps/example/ExampleServlet.java
commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/base/LookupCommand.java
commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/CatalogBase.java
commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ChainBase.java
commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ContextBase.java
commons/proper/chain/trunk/configuration/api/src/main/java/org/apache/commons/chain2/config/ConfigParser.java
commons/proper/chain/trunk/configuration/xml/src/main/java/org/apache/commons/chain2/config/xml/XmlConfigParser.java
commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ChainProcessor.java
commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/PathInfoMapper.java
commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/RequestParameterMapper.java
commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ServletPathMapper.java
Modified: commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Chain.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Chain.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Chain.java (original)
+++ commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Chain.java Tue Jun 7 00:50:15 2016
@@ -66,9 +66,9 @@ public interface Chain<K, V, C extends M
* @param <CMD> the {@link Command} type to be added in the {@link Chain}
* @param command The {@link Command} to be added
*
- * @exception IllegalArgumentException if <code>command</code>
+ * @throws IllegalArgumentException if <code>command</code>
* is <code>null</code>
- * @exception IllegalStateException if this {@link Chain} has already
+ * @throws IllegalStateException if this {@link Chain} has already
* been executed at least once, so no further configuration is allowed
*/
<CMD extends Command<K, V, C>> void addCommand(CMD command);
@@ -103,7 +103,7 @@ public interface Chain<K, V, C extends M
* @param context The {@link Context} to be processed by this
* {@link Chain}
*
- * @exception IllegalArgumentException if <code>context</code>
+ * @throws IllegalArgumentException if <code>context</code>
* is <code>null</code>
*
* @return {@link Processing#FINISHED} if the processing of this context
Modified: commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Command.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Command.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Command.java (original)
+++ commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Command.java Tue Jun 7 00:50:15 2016
@@ -94,9 +94,9 @@ public interface Command<K, V, C extends
* @param context The {@link Context} to be processed by this
* {@link Command}
*
- * @exception ChainException general purpose exception return
+ * @throws ChainException general purpose exception return
* to indicate abnormal termination
- * @exception IllegalArgumentException if <code>context</code>
+ * @throws IllegalArgumentException if <code>context</code>
* is <code>null</code>
*
* @return {@link Processing#FINISHED} if the processing of this contex
Modified: commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Filter.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Filter.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Filter.java (original)
+++ commons/proper/chain/trunk/api/src/main/java/org/apache/commons/chain2/Filter.java Tue Jun 7 00:50:15 2016
@@ -57,7 +57,7 @@ public interface Filter<K, V, C extends
* by the last {@link Command} that was executed; otherwise
* <code>null</code>
*
- * @exception IllegalArgumentException if <code>context</code>
+ * @throws IllegalArgumentException if <code>context</code>
* is <code>null</code>
*
* @return If a non-null <code>exception</code> was "handled" by this
Modified: commons/proper/chain/trunk/apps/example2/src/main/java/org/apache/commons/chain2/apps/example/ExampleServlet.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/apps/example2/src/main/java/org/apache/commons/chain2/apps/example/ExampleServlet.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/apps/example2/src/main/java/org/apache/commons/chain2/apps/example/ExampleServlet.java (original)
+++ commons/proper/chain/trunk/apps/example2/src/main/java/org/apache/commons/chain2/apps/example/ExampleServlet.java Tue Jun 7 00:50:15 2016
@@ -49,7 +49,7 @@ public class ExampleServlet extends Http
/**
* <p>Cache the name of the servlet.</p>
*
- * @exception ServletException if an initialization error occurs
+ * @throws ServletException if an initialization error occurs
*/
public void init() throws ServletException {
super.init();
@@ -69,7 +69,7 @@ public class ExampleServlet extends Http
* @param request The request we are processing
* @param response The response we are creating
*
- * @exception IOException if an input/output error occurs
+ * @throws IOException if an input/output error occurs
*/
public void service(HttpServletRequest request,
HttpServletResponse response)
Modified: commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/base/LookupCommand.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/base/LookupCommand.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/base/LookupCommand.java (original)
+++ commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/base/LookupCommand.java Tue Jun 7 00:50:15 2016
@@ -263,7 +263,7 @@ public class LookupCommand<K, V, C exten
*
* @param context The context for this request
*
- * @exception IllegalArgumentException if no such {@link Command}
+ * @throws IllegalArgumentException if no such {@link Command}
* can be found and the <code>optional</code> property is set
* to <code>false</code>
* @return the result of executing the looked-up command, or
@@ -316,7 +316,7 @@ public class LookupCommand<K, V, C exten
*
* @param context {@link Context} for this request
* @return The catalog.
- * @exception IllegalArgumentException if no {@link Catalog}
+ * @throws IllegalArgumentException if no {@link Catalog}
* can be found
*
* @since Chain 1.2
@@ -353,7 +353,7 @@ public class LookupCommand<K, V, C exten
*
* @param context {@link Context} for this request
* @return The looked-up Command.
- * @exception IllegalArgumentException if no such {@link Command}
+ * @throws IllegalArgumentException if no such {@link Command}
* can be found and the <code>optional</code> property is set
* to <code>false</code>
*/
Modified: commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/CatalogBase.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/CatalogBase.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/CatalogBase.java (original)
+++ commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/CatalogBase.java Tue Jun 7 00:50:15 2016
@@ -59,7 +59,7 @@ public class CatalogBase<K, V, C extends
*
* @param commands Map of Commands.
*
- * @exception IllegalArgumentException if <code>commands</code>
+ * @throws IllegalArgumentException if <code>commands</code>
* is <code>null</code>
*
* @since Chain 1.1
Modified: commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ChainBase.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ChainBase.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ChainBase.java (original)
+++ commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ChainBase.java Tue Jun 7 00:50:15 2016
@@ -53,7 +53,7 @@ public class ChainBase<K, V, C extends M
*
* @param command The {@link Command} to be configured
*
- * @exception IllegalArgumentException if <code>command</code>
+ * @throws IllegalArgumentException if <code>command</code>
* is <code>null</code>
*/
public ChainBase(Command<K, V, C> command) {
@@ -66,7 +66,7 @@ public class ChainBase<K, V, C extends M
*
* @param commands The {@link Command Commands} to be configured
*
- * @exception IllegalArgumentException if <code>commands</code>,
+ * @throws IllegalArgumentException if <code>commands</code>,
* or one of the individual {@link Command} elements,
* is <code>null</code>
*/
@@ -85,7 +85,7 @@ public class ChainBase<K, V, C extends M
*
* @param commands The {@link Command}s to be configured
*
- * @exception IllegalArgumentException if <code>commands</code>,
+ * @throws IllegalArgumentException if <code>commands</code>,
* or one of the individual {@link Command} elements,
* is <code>null</code>
*/
@@ -121,9 +121,9 @@ public class ChainBase<K, V, C extends M
* @param <CMD> the {@link Command} type to be added in the {@link Chain}
* @param command The {@link Command} to be added
*
- * @exception IllegalArgumentException if <code>command</code>
+ * @throws IllegalArgumentException if <code>command</code>
* is <code>null</code>
- * @exception IllegalStateException if no further configuration is allowed
+ * @throws IllegalStateException if no further configuration is allowed
*/
public <CMD extends Command<K, V, C>> void addCommand(CMD command) {
if (command == null) {
Modified: commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ContextBase.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ContextBase.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ContextBase.java (original)
+++ commons/proper/chain/trunk/base/src/main/java/org/apache/commons/chain2/impl/ContextBase.java Tue Jun 7 00:50:15 2016
@@ -72,9 +72,9 @@ public class ContextBase extends Context
*
* @param map Map whose key-value pairs are added
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* writing a local property value
- * @exception UnsupportedOperationException if a local property does not
+ * @throws UnsupportedOperationException if a local property does not
* have a write method.
*/
public ContextBase(Map<? extends String, ? extends Object> map) {
@@ -162,7 +162,7 @@ public class ContextBase extends Context
* @param value the value look for in the context.
* @return <code>true</code> if found in this context otherwise
* <code>false</code>.
- * @exception IllegalArgumentException if a property getter
+ * @throws IllegalArgumentException if a property getter
* throws an exception
*/
@Override
@@ -219,9 +219,9 @@ public class ContextBase extends Context
* @param key Key of the value to be returned
* @return The value for the specified key.
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* reading this local property value
- * @exception UnsupportedOperationException if this local property does not
+ * @throws UnsupportedOperationException if this local property does not
* have a read method.
*/
@Override
@@ -289,9 +289,9 @@ public class ContextBase extends Context
* @param value New value to be stored
* @return The value added to the Context.
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* reading or writing this local property value
- * @exception UnsupportedOperationException if this local property does not
+ * @throws UnsupportedOperationException if this local property does not
* have both a read method and a write method
*/
@Override
@@ -338,9 +338,9 @@ public class ContextBase extends Context
* @param map <code>Map</code> containing key-value pairs to store
* (or replace)
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* reading or writing a local property value
- * @exception UnsupportedOperationException if a local property does not
+ * @throws UnsupportedOperationException if a local property does not
* have both a read method and a write method
*/
@Override
@@ -358,7 +358,7 @@ public class ContextBase extends Context
* @param key Key to be removed
* @return The value removed from the Context.
*
- * @exception UnsupportedOperationException if the specified
+ * @throws UnsupportedOperationException if the specified
* <code>key</code> matches the name of a local property
*/
@Override
@@ -424,9 +424,9 @@ public class ContextBase extends Context
* the {@link Context} implementation class.</p>
*
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* writing this local property value
- * @exception UnsupportedOperationException if this local property does not
+ * @throws UnsupportedOperationException if this local property does not
* have a write method.
*/
private void initialize() {
@@ -459,9 +459,9 @@ public class ContextBase extends Context
* @param descriptor <code>PropertyDescriptor</code> for the
* specified property
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* reading this local property value
- * @exception UnsupportedOperationException if this local property does not
+ * @throws UnsupportedOperationException if this local property does not
* have a read method.
*/
private Object readProperty(PropertyDescriptor descriptor) {
@@ -487,7 +487,7 @@ public class ContextBase extends Context
*
* @param entry Key-value pair to be removed
*
- * @exception UnsupportedOperationException if the specified key
+ * @throws UnsupportedOperationException if the specified key
* identifies a property instead of an attribute
*/
private boolean remove(Map.Entry<String, Object> entry) {
@@ -518,9 +518,9 @@ public class ContextBase extends Context
* @param value The new value for this property (must be of the
* correct type)
*
- * @exception IllegalArgumentException if an exception is thrown
+ * @throws IllegalArgumentException if an exception is thrown
* writing this local property value
- * @exception UnsupportedOperationException if this local property does not
+ * @throws UnsupportedOperationException if this local property does not
* have a write method.
*/
private void writeProperty(PropertyDescriptor descriptor, Object value) {
Modified: commons/proper/chain/trunk/configuration/api/src/main/java/org/apache/commons/chain2/config/ConfigParser.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/configuration/api/src/main/java/org/apache/commons/chain2/config/ConfigParser.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/configuration/api/src/main/java/org/apache/commons/chain2/config/ConfigParser.java (original)
+++ commons/proper/chain/trunk/configuration/api/src/main/java/org/apache/commons/chain2/config/ConfigParser.java Tue Jun 7 00:50:15 2016
@@ -47,7 +47,7 @@ public interface ConfigParser {
* @param <C> Type of the context associated with this command
* @param url <code>URL</code> of the configuration document to be parsed
* @return a CatalogFactory instance parsed from the given location
- * @exception ChainConfigurationException if a parsing error occurs
+ * @throws ChainConfigurationException if a parsing error occurs
*/
<K, V, C extends Map<K, V>> CatalogFactory<K, V, C> parse(URL url) throws ChainConfigurationException;
Modified: commons/proper/chain/trunk/configuration/xml/src/main/java/org/apache/commons/chain2/config/xml/XmlConfigParser.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/configuration/xml/src/main/java/org/apache/commons/chain2/config/xml/XmlConfigParser.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/configuration/xml/src/main/java/org/apache/commons/chain2/config/xml/XmlConfigParser.java (original)
+++ commons/proper/chain/trunk/configuration/xml/src/main/java/org/apache/commons/chain2/config/xml/XmlConfigParser.java Tue Jun 7 00:50:15 2016
@@ -145,7 +145,7 @@ public class XmlConfigParser implements
* @param <C> Type of the context associated with this command
* @param url <code>URL</code> of the XML document to be parsed
* @return a CatalogFactory instance parsed from the given location
- * @exception ChainConfigurationException if a parsing error occurs
+ * @throws ChainConfigurationException if a parsing error occurs
*/
public <K, V, C extends Map<K, V>> CatalogFactory<K, V, C> parse(URL url) {
// Prepare our Digester instance
Modified: commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ChainProcessor.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ChainProcessor.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ChainProcessor.java (original)
+++ commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ChainProcessor.java Tue Jun 7 00:50:15 2016
@@ -132,7 +132,7 @@ public class ChainProcessor extends Chai
/**
* <p>Cache the name of the command we should execute for each request.</p>
*
- * @exception ServletException if an initialization error occurs
+ * @throws ServletException if an initialization error occurs
*/
@Override
public void init() throws ServletException {
@@ -153,8 +153,8 @@ public class ChainProcessor extends Chai
* @param request The request we are processing
* @param response The response we are creating
*
- * @exception IOException if an input/output error occurs
- * @exception ServletException if a servlet exception occurs
+ * @throws IOException if an input/output error occurs
+ * @throws ServletException if a servlet exception occurs
*/
@Override
public void service(HttpServletRequest request, HttpServletResponse response)
Modified: commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/PathInfoMapper.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/PathInfoMapper.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/PathInfoMapper.java (original)
+++ commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/PathInfoMapper.java Tue Jun 7 00:50:15 2016
@@ -65,7 +65,7 @@ public class PathInfoMapper extends Look
*
* @param context {@link Context} for this request
* @return The catalog.
- * @exception IllegalArgumentException if no {@link Catalog}
+ * @throws IllegalArgumentException if no {@link Catalog}
* can be found
*
* @since Chain 1.2
Modified: commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/RequestParameterMapper.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/RequestParameterMapper.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/RequestParameterMapper.java (original)
+++ commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/RequestParameterMapper.java Tue Jun 7 00:50:15 2016
@@ -90,7 +90,7 @@ public class RequestParameterMapper
*
* @param context {@link Context} for this request
* @return The catalog.
- * @exception IllegalArgumentException if no {@link Catalog}
+ * @throws IllegalArgumentException if no {@link Catalog}
* can be found
*
* @since Chain 1.2
Modified: commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ServletPathMapper.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ServletPathMapper.java?rev=1747104&r1=1747103&r2=1747104&view=diff
==============================================================================
--- commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ServletPathMapper.java (original)
+++ commons/proper/chain/trunk/web/src/main/java/org/apache/commons/chain2/web/servlet/ServletPathMapper.java Tue Jun 7 00:50:15 2016
@@ -65,7 +65,7 @@ public class ServletPathMapper extends L
*
* @param context {@link Context} for this request
* @return The catalog.
- * @exception IllegalArgumentException if no {@link Catalog}
+ * @throws IllegalArgumentException if no {@link Catalog}
* can be found
*
* @since Chain 1.2