|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--JavaElement
JavaElement is the superclass of all components of a runnable Java program.
This abstract class contains or defines the methods necessary for the decisions whether a component is needed in the resulting program. This class supports different modes of being needed, e.g. a class can be
In addition to the basic modes described above (excluding one another) there are add-on modes that can be combined with the basic modes and with one another.
Basic modes range from 0 to 255, add-on modes are bit masks from 256 upwards.
Field Summary | |
(package private) static int |
EXACT_INSTANCE_NEEDED
needed-mode constant: instances of this class needed with byte-exact layout of all fields. |
(package private) static int |
INSTANCE_NEEDED
needed-mode constant: instances of this class needed. |
(package private) static int |
NEEDED
needed-mode constant: needed in default-mode. |
(package private) static int |
NEEDED_INSTANCEOF
needed-mode constant for classes: instances of other classes are checked to belong to this class. |
(package private) static int |
NEEDED_VIRTUALLY
needed-mode constant: method is being called virtually. |
(package private) int |
neededModeAddOn
the add-on modes modifying how this element is needed. |
(package private) int |
neededModeBasic
the basic mode describing how this element is needed. |
(package private) java.util.Vector |
neededReasons
reasons why this element is needed. |
(package private) static int |
UNNEEDED
needed-mode constant: element unneeded |
Constructor Summary | |
(package private) |
JavaElement()
|
Method Summary | |
(package private) boolean |
isNeeded()
check whether this element is needed in any mode. |
(package private) boolean |
isNeeded(int mode)
check whether this element is needed at least in the specified mode. |
(package private) void |
markNeeded(java.lang.Object reason,
int mode)
mark this Java element needed in a specific mode, adding logically to the current mode. |
(package private) abstract void |
updateNeeded()
update the 'needed'-state of all Java elements that this one depends upon. |
Methods inherited from class java.lang.Object |
|
Field Detail |
static final int UNNEEDED
static final int NEEDED
static final int INSTANCE_NEEDED
static final int EXACT_INSTANCE_NEEDED
static final int NEEDED_VIRTUALLY
NEEDED_VIRTUALLY can be combined with UNNEEDED, if only subclasses of the method's class have instances and all the subclasses have their own implementation of the method. Then there's no chance that the method being called virtually is really executed - the subclass methods will be executed instead.
static final int NEEDED_INSTANCEOF
int neededModeBasic
int neededModeAddOn
java.util.Vector neededReasons
Constructor Detail |
JavaElement()
Method Detail |
void markNeeded(java.lang.Object reason, int mode)
reason
- the reason why this element is needed
(normally another Java element referencing this one).mode
- a mode constant describing how this element is needed.boolean isNeeded(int mode)
boolean isNeeded()
abstract void updateNeeded()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |