Author: markt
Date: Tue Feb 19 20:36:34 2013
New Revision: 1447907
URL: http://svn.apache.org/r1447907
Log:
UCDetector: Remove unused constructors
Modified:
tomcat/trunk/java/org/apache/tomcat/util/digester/CallMethodRule.java
tomcat/trunk/java/org/apache/tomcat/util/digester/CallParamRule.java
tomcat/trunk/java/org/apache/tomcat/util/digester/FactoryCreateRule.java
tomcat/trunk/java/org/apache/tomcat/util/digester/ObjectCreateRule.java
tomcat/trunk/java/org/apache/tomcat/util/digester/SetNextRule.java
tomcat/trunk/java/org/apache/tomcat/util/digester/SetPropertiesRule.java
Modified: tomcat/trunk/java/org/apache/tomcat/util/digester/CallMethodRule.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/digester/CallMethodRule.java?rev=1447907&r1=1447906&r2=1447907&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/digester/CallMethodRule.java
(original)
+++ tomcat/trunk/java/org/apache/tomcat/util/digester/CallMethodRule.java Tue
Feb 19 20:36:34 2013
@@ -138,51 +138,6 @@ public class CallMethodRule extends Rule
* @param methodName Method name of the parent method to call
* @param paramCount The number of parameters to collect, or
* zero for a single argument from the body of this element
- * @param paramTypes The Java class names of the arguments
- * (if you wish to use a primitive type, specify the corresponding
- * Java wrapper class instead, such as <code>java.lang.Boolean</code>
- * for a <code>boolean</code> parameter)
- */
- public CallMethodRule( int targetOffset,
- String methodName,
- int paramCount,
- String paramTypes[]) {
-
- this.targetOffset = targetOffset;
- this.methodName = methodName;
- this.paramCount = paramCount;
- if (paramTypes == null) {
- this.paramTypes = new Class[paramCount];
- for (int i = 0; i < this.paramTypes.length; i++) {
- this.paramTypes[i] = String.class;
- }
- this.paramClassNames = null;
- } else {
- // copy the parameter class names into an array
- // the classes will be loaded when the digester is set
- this.paramClassNames = new String[paramTypes.length];
- for (int i = 0; i < this.paramClassNames.length; i++) {
- this.paramClassNames[i] = paramTypes[i];
- }
- }
-
- }
-
-
- /**
- * Construct a "call method" rule with the specified method name and
- * parameter types. If <code>paramCount</code> is set to zero the rule
- * will use the body of this element as the single argument of the
- * method, unless <code>paramTypes</code> is null or empty, in this
- * case the rule will call the specified method with no arguments.
- *
- * @param targetOffset location of the target object. Positive numbers are
- * relative to the top of the digester object stack. Negative numbers
- * are relative to the bottom of the stack. Zero implies the top
- * object on the stack.
- * @param methodName Method name of the parent method to call
- * @param paramCount The number of parameters to collect, or
- * zero for a single argument from the body of this element
* @param paramTypes The Java classes that represent the
* parameter types of the method arguments
* (if you wish to use a primitive type, specify the corresponding
Modified: tomcat/trunk/java/org/apache/tomcat/util/digester/CallParamRule.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/digester/CallParamRule.java?rev=1447907&r1=1447906&r2=1447907&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/digester/CallParamRule.java
(original)
+++ tomcat/trunk/java/org/apache/tomcat/util/digester/CallParamRule.java Tue
Feb 19 20:36:34 2013
@@ -67,28 +67,6 @@ public class CallParamRule extends Rule
}
- /**
- * Construct a "call parameter" rule.
- *
- * @param paramIndex The zero-relative parameter number
- * @param fromStack should this parameter be taken from the top of the
stack?
- */
- public CallParamRule(int paramIndex, boolean fromStack) {
- this(null, paramIndex, 0, fromStack);
- }
-
- /**
- * Constructs a "call parameter" rule which sets a parameter from the
stack.
- * If the stack contains too few objects, then the parameter will be set
to null.
- *
- * @param paramIndex The zero-relative parameter number
- * @param stackIndex the index of the object which will be passed as a
parameter.
- * The zeroth object is the top of the stack, 1 is the next object down
and so on.
- */
- public CallParamRule(int paramIndex, int stackIndex) {
- this(null, paramIndex, stackIndex, true);
- }
-
private CallParamRule(String attributeName, int paramIndex, int stackIndex,
boolean fromStack) {
this.attributeName = attributeName;
Modified:
tomcat/trunk/java/org/apache/tomcat/util/digester/FactoryCreateRule.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/digester/FactoryCreateRule.java?rev=1447907&r1=1447906&r2=1447907&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/digester/FactoryCreateRule.java
(original)
+++ tomcat/trunk/java/org/apache/tomcat/util/digester/FactoryCreateRule.java
Tue Feb 19 20:36:34 2013
@@ -41,42 +41,8 @@ public class FactoryCreateRule extends R
/** Stock to manage */
private ArrayStack<Boolean> exceptionIgnoredStack;
- // ----------------------------------------------------------- Constructors
-
-
- /**
- * Construct a factory create rule that will use the specified
- * class name to create an {@link ObjectCreationFactory} which will
- * then be used to create an object and push it on the stack.
- *
- * @param className Java class name of the object creation factory class
- * @param ignoreCreateExceptions if true, exceptions thrown by the object
- * creation factory
- * will be ignored.
- */
- public FactoryCreateRule(String className, boolean ignoreCreateExceptions)
{
-
- this(className, null, ignoreCreateExceptions);
-
- }
-
-
- /**
- * Construct a factory create rule that will use the specified
- * class to create an {@link ObjectCreationFactory} which will
- * then be used to create an object and push it on the stack.
- *
- * @param clazz Java class name of the object creation factory class
- * @param ignoreCreateExceptions if true, exceptions thrown by the
- * object creation factory
- * will be ignored.
- */
- public FactoryCreateRule(Class<?> clazz, boolean ignoreCreateExceptions) {
-
- this(clazz, null, ignoreCreateExceptions);
-
- }
+ // ----------------------------------------------------------- Constructors
/**
* Construct a factory create rule that will use the specified
Modified:
tomcat/trunk/java/org/apache/tomcat/util/digester/ObjectCreateRule.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/digester/ObjectCreateRule.java?rev=1447907&r1=1447906&r2=1447907&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/digester/ObjectCreateRule.java
(original)
+++ tomcat/trunk/java/org/apache/tomcat/util/digester/ObjectCreateRule.java Tue
Feb 19 20:36:34 2013
@@ -47,18 +47,6 @@ public class ObjectCreateRule extends Ru
/**
- * Construct an object create rule with the specified class.
- *
- * @param clazz Java class name of the object to be created
- */
- public ObjectCreateRule(Class<?> clazz) {
-
- this(clazz.getName(), (String) null);
-
- }
-
-
- /**
* Construct an object create rule with the specified class name and an
* optional attribute name containing an override.
*
@@ -75,24 +63,8 @@ public class ObjectCreateRule extends Ru
}
- /**
- * Construct an object create rule with the specified class and an
- * optional attribute name containing an override.
- *
- * @param attributeName Attribute name which, if present, contains an
- * @param clazz Java class name of the object to be created
- * override of the class name to create
- */
- public ObjectCreateRule(String attributeName,
- Class<?> clazz) {
-
- this(clazz.getName(), attributeName);
-
- }
-
// ----------------------------------------------------- Instance Variables
-
/**
* The attribute containing an override class name if it is present.
*/
Modified: tomcat/trunk/java/org/apache/tomcat/util/digester/SetNextRule.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/digester/SetNextRule.java?rev=1447907&r1=1447906&r2=1447907&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/digester/SetNextRule.java
(original)
+++ tomcat/trunk/java/org/apache/tomcat/util/digester/SetNextRule.java Tue Feb
19 20:36:34 2013
@@ -37,20 +37,6 @@ public class SetNextRule extends Rule {
// ----------------------------------------------------------- Constructors
/**
- * Construct a "set next" rule with the specified method name. The
- * method's argument type is assumed to be the class of the
- * child object.
- *
- * @param methodName Method name of the parent method to call
- */
- public SetNextRule(String methodName) {
-
- this(methodName, null);
-
- }
-
-
- /**
* Construct a "set next" rule with the specified method name.
*
* @param methodName Method name of the parent method to call
Modified:
tomcat/trunk/java/org/apache/tomcat/util/digester/SetPropertiesRule.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/digester/SetPropertiesRule.java?rev=1447907&r1=1447906&r2=1447907&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/digester/SetPropertiesRule.java
(original)
+++ tomcat/trunk/java/org/apache/tomcat/util/digester/SetPropertiesRule.java
Tue Feb 19 20:36:34 2013
@@ -36,85 +36,6 @@ import org.xml.sax.Attributes;
public class SetPropertiesRule extends Rule {
- // ----------------------------------------------------------- Constructors
-
-
- /**
- * Base constructor.
- */
- public SetPropertiesRule() {
-
- // nothing to set up
-
- }
-
- /**
- * <p>Convenience constructor overrides the mapping for just one
property.</p>
- *
- * <p>For details about how this works, see
- * {@link #SetPropertiesRule(String[] attributeNames, String[]
propertyNames)}.</p>
- *
- * @param attributeName map this attribute
- * @param propertyName to a property with this name
- */
- public SetPropertiesRule(String attributeName, String propertyName) {
-
- attributeNames = new String[1];
- attributeNames[0] = attributeName;
- propertyNames = new String[1];
- propertyNames[0] = propertyName;
- }
-
- /**
- * <p>Constructor allows attribute->property mapping to be overridden.</p>
- *
- * <p>Two arrays are passed in.
- * One contains the attribute names and the other the property names.
- * The attribute name / property name pairs are match by position
- * In order words, the first string in the attribute name list matches
- * to the first string in the property name list and so on.</p>
- *
- * <p>If a property name is null or the attribute name has no matching
- * property name, then this indicates that the attribute should be
ignored.</p>
- *
- * <h5>Example One</h5>
- * <p> The following constructs a rule that maps the <code>alt-city</code>
- * attribute to the <code>city</code> property and the
<code>alt-state</code>
- * to the <code>state</code> property.
- * All other attributes are mapped as usual using exact name matching.
- * <code><pre>
- * SetPropertiesRule(
- * new String[] {"alt-city", "alt-state"},
- * new String[] {"city", "state"});
- * </pre></code>
- *
- * <h5>Example Two</h5>
- * <p> The following constructs a rule that maps the <code>class</code>
- * attribute to the <code>className</code> property.
- * The attribute <code>ignore-me</code> is not mapped.
- * All other attributes are mapped as usual using exact name matching.
- * <code><pre>
- * SetPropertiesRule(
- * new String[] {"class", "ignore-me"},
- * new String[] {"className"});
- * </pre></code>
- *
- * @param attributeNames names of attributes to map
- * @param propertyNames names of properties mapped to
- */
- public SetPropertiesRule(String[] attributeNames, String[] propertyNames) {
- // create local copies
- this.attributeNames = new String[attributeNames.length];
- for (int i=0, size=attributeNames.length; i<size; i++) {
- this.attributeNames[i] = attributeNames[i];
- }
-
- this.propertyNames = new String[propertyNames.length];
- for (int i=0, size=propertyNames.length; i<size; i++) {
- this.propertyNames[i] = propertyNames[i];
- }
- }
-
// ----------------------------------------------------- Instance Variables
/**
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]