mx4j.tools.adaptor.http
Class CommandProcessorUtil
java.lang.Object
mx4j.tools.adaptor.http.CommandProcessorUtil
public class CommandProcessorUtil
extends java.lang.Object
Contains utilities common to CommandProcessor objects
canCreateParameterValue
protected static boolean canCreateParameterValue(String parameterType)
Checks if the given type is primitive of can be initialized from String.
This is done by trying to load the class and checking if there is a public String
only constructor.
parameterType
- Indicates the type of the parameter, for instance java.lang.String
- true if the type is primitive or String initializable
createClassComparator
public static Comparator createClassComparator()
createConstructorComparator
public static Comparator createConstructorComparator()
createObjectInstanceComparator
public static Comparator createObjectInstanceComparator()
createObjectNameComparator
public static Comparator createObjectNameComparator()
createParameterValue
protected static Object createParameterValue(String parameterType,
String parameterValue)
throws Exception
Creates a parameter object of the given type containing a given value.
If the type is unknown null is returned
parameterType
- Indicates the type of the parameter, for instance java.lang.StringparameterValue
- The value of the parameter as a String
- an object of parameterType type and value parameterValue or null if the type is unknown
Copyright © 2001-2005 The MX4J Contributors. All Rights Reserved.