Package com.j_spaces.kernel
Class ClassHelper
java.lang.Object
com.j_spaces.kernel.ClassHelper
Helper for setting/getting any public properties.
- Version:
- 4.0
- Author:
- Gershon Diner
-
Method Summary
Modifier and TypeMethodDescriptionstatic MethodHelper to return a method given its name and a list of argumentsstatic StringgetPrimitiveName(Class wrapper) Helper to return the primitive type name associated with an object wrapper typestatic ClassgetPrimitiveType(Class wrapper) Helper to return the primitive type associated with an object wrapper type
-
Method Details
-
getMethod
Helper to return a method given its name and a list of arguments- Parameters:
type- the class to locate the method onname- the method nameargs- the list of arguments to match against, or null if the method takes no arguments- Returns:
- the method matching the name and list of arguments
- Throws:
NoSuchMethodException- if the method cannot be found
-
getPrimitiveType
Helper to return the primitive type associated with an object wrapper type- Parameters:
wrapper- the object wrapper class- Returns:
- the associated primitive type, or the wrapper type, if there is no associated primitive type
-
getPrimitiveName
Helper to return the primitive type name associated with an object wrapper type- Parameters:
wrapper- the object wrapper class- Returns:
- the associated primitive type name, or the wrapper type name, if there is no
associated primitive type. Array types are returned in the form '
[]'
-