public enum Target extends Enum<Target>
This is NOT part of any supported API. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.
Enum Constant and Description |
---|
JDK1_1 |
JDK1_2 |
JDK1_3 |
JDK1_4
J2SE1.4 = Merlin.
|
JDK1_5
Tiger.
|
JDK1_6
JDK 6.
|
JDK1_7
JDK 7.
|
JDK1_8
JDK 8.
|
Modifier and Type | Field and Description |
---|---|
static Target |
DEFAULT |
int |
majorVersion |
int |
minorVersion |
String |
name |
Modifier and Type | Method and Description |
---|---|
boolean |
arrayBinaryCompatibility()
Starting in 1.5, the compiler uses an array type as
the qualifier for method calls (such as clone) where required by
the language and VM spec.
|
boolean |
boxWithConstructors()
For bootstrapping, we use J2SE1.4's wrapper class constructors
to implement boxing.
|
boolean |
classLiteralsNoInit()
Although we may not have support for class literals, should we
avoid initializing the class that the literal refers to?
See 4468823
|
boolean |
generateCLDCStackmap()
Return true if cldc-style stack maps need to be generated.
|
boolean |
generateEmptyAfterBig()
Do we generate "empty" stackmap slots after double and long?
|
boolean |
generateStackMapTable()
Beginning in -target 6, we generate stackmap attribute in
compact format.
|
boolean |
hasClassLiterals()
Does the VM have direct support for class literals?
|
boolean |
hasEnclosingMethodAttribute()
In J2SE1.5.0, we introduced the "EnclosingMethod" attribute
for improved reflection support.
|
boolean |
hasInitCause()
Although we may not have support for class literals, when we
throw a NoClassDefFoundError, should we initialize its cause?
|
boolean |
hasInvokedynamic()
Does the VM support an invokedynamic instruction?
|
boolean |
hasIterable()
For bootstrapping, we use J2SE1.4's java.util.Collection
instead of java.lang.Iterable.
|
boolean |
hasMethodHandles()
Does the VM support polymorphic method handle invocation?
Affects the linkage information output to the classfile.
|
boolean |
initializeFieldsBeforeSuper()
Beginning in 1.4, we take advantage of the possibility of emitting
code to initialize fields before calling the superclass constructor.
|
static Target |
instance(Context context) |
boolean |
interfaceFieldsBinaryCompatibility()
Beginning after 1.2, we follow the binary compatibility rules for
interface fields.
|
boolean |
interfaceObjectOverridesBinaryCompatibility()
Beginning in -target 1.5, we follow the binary compatibility
rules for interface methods that redefine Object methods.
|
boolean |
isPackageInfoSynthetic()
Beginning in -target 6, package-info classes are marked synthetic.
|
static Target |
lookup(String name) |
static Target |
MAX() |
static Target |
MIN() |
boolean |
obeyBinaryCompatibility()
Beginning with -target 1.2 we obey the JLS rules for binary
compatibility, emitting as the qualifying type of a reference
to a method or field the type of the qualifier.
|
boolean |
requiresIproxy()
In -target 1.1 and earlier, the compiler is required to emit
synthetic method definitions in abstract classes for interface
methods that are not overridden.
|
char |
syntheticNameChar()
Return the character to be used in constructing synthetic
identifiers, where not specified by the JLS.
|
boolean |
useAnnotationFlag() |
boolean |
useBridgeFlag() |
boolean |
useEnumFlag() |
boolean |
useInnerCacheClass()
Sometimes we need to create a field to cache a value like a
class literal of the assertions flag.
|
boolean |
usePrivateSyntheticFields()
Beginning in -target 1.5, we make synthetic variables
package-private instead of private.
|
boolean |
useStringBuilder()
Beginning in 1.5, we have an unsynchronized version of
StringBuffer called StringBuilder that can be used by the
compiler for string concatenation.
|
boolean |
useSyntheticFlag()
Beginning in 1.5, we have flag bits we can use instead of
marker attributes.
|
boolean |
useVarargsFlag() |
static Target |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Target[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Target JDK1_1
public static final Target JDK1_2
public static final Target JDK1_3
public static final Target JDK1_4
public static final Target JDK1_5
public static final Target JDK1_6
public static final Target JDK1_7
public static final Target JDK1_8
public final String name
public final int majorVersion
public final int minorVersion
public static final Target DEFAULT
public static Target[] values()
for (Target c : Target.values()) System.out.println(c);
public static Target valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static Target MIN()
public static Target MAX()
public boolean requiresIproxy()
public boolean initializeFieldsBeforeSuper()
public boolean obeyBinaryCompatibility()
public boolean arrayBinaryCompatibility()
public boolean interfaceFieldsBinaryCompatibility()
public boolean interfaceObjectOverridesBinaryCompatibility()
public boolean usePrivateSyntheticFields()
public boolean useInnerCacheClass()
public boolean generateCLDCStackmap()
public boolean generateStackMapTable()
public boolean isPackageInfoSynthetic()
public boolean generateEmptyAfterBig()
public boolean useStringBuilder()
public boolean useSyntheticFlag()
public boolean useEnumFlag()
public boolean useAnnotationFlag()
public boolean useVarargsFlag()
public boolean useBridgeFlag()
public char syntheticNameChar()
public boolean hasClassLiterals()
public boolean hasInvokedynamic()
public boolean hasMethodHandles()
hasInvokedynamic
, since all the JSR 292 features appear together.public boolean classLiteralsNoInit()
public boolean hasInitCause()
public boolean boxWithConstructors()
public boolean hasIterable()
public boolean hasEnclosingMethodAttribute()
Copyright © 2017 earcam. All rights reserved.