net.sf.crispy.util
Class Invoker
java.lang.Object
net.sf.crispy.util.Invoker
- public final class Invoker
- extends java.lang.Object
Work with reflection API.
- Author:
- Linke
Method Summary |
static java.lang.Object[] |
array2SimpleArray(java.lang.Object[] pvArray,
Converter pvConverter)
|
static java.util.Vector |
array2SimpleVector(java.lang.Object[] pvArray)
|
static java.util.Vector |
array2Vector(java.lang.Object[] pvArray)
|
static java.lang.reflect.Method[] |
findAllMethods(java.lang.Class pvClass,
java.lang.String pvMethodName)
|
static java.lang.reflect.Method |
findMethod(java.lang.Class pvClass,
java.lang.String pvMethodName,
java.util.List pvParams)
|
static java.lang.Object |
invoke(java.lang.Object pvObject,
java.lang.String pvMethodName,
java.util.Vector pvParams,
boolean pvWithConverter,
Converter pvConverter)
|
static java.lang.Object |
invoke(java.lang.String pvClassName,
java.lang.String pvMethodName,
java.util.Vector pvParams,
boolean pvWithConverter,
Converter pvConverter)
|
static java.lang.Object |
invokeWithConverter(java.lang.Object pvObject,
java.lang.String pvMethodName,
java.util.Vector pvParams,
Converter pvConverter)
Invoke method from pvObject with the method-name (pvMethodName) and parameter (pvPrams) via reflection. |
static boolean |
isCompatibleType(java.lang.Class pvType1,
java.lang.Class pvType2)
|
static java.lang.Object[] |
vector2Array(java.util.Vector pvVector,
java.lang.reflect.Method pvMethod,
Converter pvConverter)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
invokeWithConverter
public static java.lang.Object invokeWithConverter(java.lang.Object pvObject,
java.lang.String pvMethodName,
java.util.Vector pvParams,
Converter pvConverter)
throws java.lang.Exception
- Invoke method from pvObject with the method-name (pvMethodName) and parameter (pvPrams) via reflection.
- Parameters:
pvObject
- object for the method callpvMethodName
- name of methodpvParams
- parameter for method
- Returns:
- the return value from the method call
- Throws:
java.lang.Exception
invoke
public static java.lang.Object invoke(java.lang.String pvClassName,
java.lang.String pvMethodName,
java.util.Vector pvParams,
boolean pvWithConverter,
Converter pvConverter)
throws java.lang.Exception
- Throws:
java.lang.Exception
invoke
public static java.lang.Object invoke(java.lang.Object pvObject,
java.lang.String pvMethodName,
java.util.Vector pvParams,
boolean pvWithConverter,
Converter pvConverter)
throws java.lang.Exception
- Throws:
java.lang.Exception
vector2Array
public static java.lang.Object[] vector2Array(java.util.Vector pvVector,
java.lang.reflect.Method pvMethod,
Converter pvConverter)
throws java.lang.Exception
- Throws:
java.lang.Exception
isCompatibleType
public static boolean isCompatibleType(java.lang.Class pvType1,
java.lang.Class pvType2)
findMethod
public static java.lang.reflect.Method findMethod(java.lang.Class pvClass,
java.lang.String pvMethodName,
java.util.List pvParams)
throws java.lang.Exception
- Throws:
java.lang.Exception
findAllMethods
public static java.lang.reflect.Method[] findAllMethods(java.lang.Class pvClass,
java.lang.String pvMethodName)
throws java.lang.Exception
- Throws:
java.lang.Exception
array2Vector
public static java.util.Vector array2Vector(java.lang.Object[] pvArray)
throws java.lang.Exception
- Throws:
java.lang.Exception
array2SimpleVector
public static java.util.Vector array2SimpleVector(java.lang.Object[] pvArray)
throws java.lang.Exception
- Throws:
java.lang.Exception
array2SimpleArray
public static java.lang.Object[] array2SimpleArray(java.lang.Object[] pvArray,
Converter pvConverter)
throws java.lang.Exception
- Throws:
java.lang.Exception
Copyright © 2005-2006 Crispy. All Rights Reserved.