Java Code Examples for sun.tools.java.Type#toString()
The following examples show how to use
sun.tools.java.Type#toString() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: RMIGenerator.java From dragonwell8_jdk with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 2
Source File: RMIGenerator.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 3
Source File: RMIGenerator.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 4
Source File: RMIGenerator.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 5
Source File: RMIGenerator.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 6
Source File: RMIGenerator.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 7
Source File: RMIGenerator.java From jdk8u-jdk with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 8
Source File: RMIGenerator.java From hottub with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 9
Source File: RMIGenerator.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 10
Source File: RMIGenerator.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 11
Source File: RMIGenerator.java From jdk8u_jdk with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 12
Source File: RMIGenerator.java From jdk8u-jdk with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }
Example 13
Source File: RMIGenerator.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 6 votes |
/** * Generate a readable string representing the given type suitable * for embedding within a Java identifier. */ private static String generateNameFromType(Type type) { int typeCode = type.getTypeCode(); switch (typeCode) { case TC_BOOLEAN: case TC_BYTE: case TC_CHAR: case TC_SHORT: case TC_INT: case TC_LONG: case TC_FLOAT: case TC_DOUBLE: return type.toString(); case TC_ARRAY: return "arrayOf_" + generateNameFromType(type.getElementType()); case TC_CLASS: return Names.mangleClass(type.getClassName().getName()).toString(); default: throw new Error("unexpected type code: " + typeCode); } }