| java.lang.Object org.pnuts.lib.BeanClassGenerator
BeanClassGenerator | public class BeanClassGenerator (Code) | | |
Method Summary | |
static String | capitalize(String s) | static void | emit(ClassFile cf, String propertyName, Class type) | public static Class | generate(Map typeMap, String className, String superClassName, String[] interfaces) Generates a JavaBeans class from type map
Parameters: typeName - [propertyName, type] mapping Parameters: className - the class name Parameters: superClassName - the super class mame, null implies java.lang.Object Parameters: interfaces - the array of interface names, null if none. | public static Class | generate(Map typeMap, String className, String superClassName, String[] interfaces, ClassLoader loader) | public static void | generate(Map typeMap, String className, String superClassName, String[] interfaces, OutputStream out) Generates a JavaBeans class from type map,
and write the byte code to the specified output stream. | public static ClassFile | generateClassFile(Map typeMap, String className, String superClassName, String[] interfaces, String[] constructorParams) | static String | getterName(String property, Class type) | static String | makeSignature(Class type, Class returnType) | static String | setterName(String property) |
capitalize | static String capitalize(String s)(Code) | | |
generate | public static Class generate(Map typeMap, String className, String superClassName, String[] interfaces) throws IOException(Code) | | Generates a JavaBeans class from type map
Parameters: typeName - [propertyName, type] mapping Parameters: className - the class name Parameters: superClassName - the super class mame, null implies java.lang.Object Parameters: interfaces - the array of interface names, null if none. the generated class |
generate | public static Class generate(Map typeMap, String className, String superClassName, String[] interfaces, ClassLoader loader) throws IOException(Code) | | Generates a JavaBeans class from type map
Parameters: typeName - [propertyName, type] mapping Parameters: className - the class name Parameters: superClassName - the super class mame, null implies java.lang.Object Parameters: interfaces - the array of interface names, null if none. Parameters: loader - the parent ClassLoader the generated class |
generate | public static void generate(Map typeMap, String className, String superClassName, String[] interfaces, OutputStream out) throws IOException(Code) | | Generates a JavaBeans class from type map,
and write the byte code to the specified output stream.
Parameters: typeName - [propertyName, type] mapping Parameters: className - the class name Parameters: superClassName - the super class mame, null implies java.lang.Object Parameters: interfaces - the array of interface names, null if none. Parameters: out - the output stream |
generateClassFile | public static ClassFile generateClassFile(Map typeMap, String className, String superClassName, String[] interfaces, String[] constructorParams)(Code) | | |
getterName | static String getterName(String property, Class type)(Code) | | |
setterName | static String setterName(String property)(Code) | | |
|
|