==.
| Modifier and Type | Field and Description |
|---|---|
| private final String | descriptor
|
| private static final HashMap | internTable
|
| private StdTypeList | parameterFrameTypes
|
| private final StdTypeList | parameterTypes
|
| private final Type | returnType
|
| Access | Constructor and Description |
|---|---|
| private | Prototype(String
non-null; the descriptor stringConstructs an instance. |
| Modifier and Type | Method and Description |
|---|---|
| public int | compareTo(Prototype
the object to be compared. other)Implements java. |
| public boolean | equals(Object
the reference object with which to compare. other)Overrides java. |
| public String | |
| public StdTypeList | Returns: non-null; the list of parameter frame typesGets the list of frame types corresponding to the list of parameter types. |
| public StdTypeList | |
| public Type | |
| public int | |
| public static Prototype | |
| public static Prototype | Returns: non-null; the interned instancenon-null; the descriptor stringnon-null; class the method is defined onwhether this is a static method isStatic, boolean whether this is an init method isInit)Interns an instance, adding to the descriptor as necessary based on the given definer, name, and flags. |
| public static Prototype | Returns: non-null; the interned instancenon-null; the return type> 0; the number of elements in the prototypeInterns an instance which consists of the given number of
|
| private static Type[] | Returns: non-null; array large enough to hold all parsed parameter
types, but which is likely actually larger than needednon-null; the descriptor stringHelper for |
| private static Prototype | |
| public String | |
| public Prototype | Returns: non-null; an appropriately-constructed instancenon-null; the new first parameterReturns a new interned instance, which is the same as this instance, except that it has an additional parameter prepended to the original's argument list. |
| descriptor | back to summary |
|---|---|
| private final String descriptor
| |
| internTable | back to summary |
|---|---|
| private static final HashMap<String, Prototype> internTable
| |
| parameterFrameTypes | back to summary |
|---|---|
| private StdTypeList parameterFrameTypes
| |
| parameterTypes | back to summary |
|---|---|
| private final StdTypeList parameterTypes
| |
| returnType | back to summary |
|---|---|
| private final Type returnType
| |
| Prototype | back to summary |
|---|---|
| private Prototype(String descriptor, Type returnType, StdTypeList parameterTypes) Constructs an instance. This is a private constructor; use one of the public static methods to get instances.
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(Prototype other) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object other) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| getDescriptor | back to summary |
|---|---|
| public String getDescriptor() Gets the descriptor string.
| |
| getParameterFrameTypes | back to summary |
|---|---|
| public StdTypeList getParameterFrameTypes() Gets the list of frame types corresponding to the list of parameter
types. The difference between the two lists (if any) is that all
"intlike" types (see
| |
| getParameterTypes | back to summary |
|---|---|
| public StdTypeList getParameterTypes() Gets the list of parameter types.
| |
| getReturnType | back to summary |
|---|---|
| public Type getReturnType() Gets the return type.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| intern | back to summary |
|---|---|
| public static Prototype intern(String descriptor) Returns the unique instance corresponding to the given method descriptor. See vmspec-2 sec4.3.3 for details on the field descriptor syntax.
| |
| intern | back to summary |
|---|---|
| public static Prototype intern(String descriptor, Type definer, boolean isStatic, boolean isInit) Interns an instance, adding to the descriptor as necessary based
on the given definer, name, and flags. For example, an init
method has an uninitialized object of type | |
| internInts | back to summary |
|---|---|
| public static Prototype internInts(Type returnType, int count) Interns an instance which consists of the given number of
| |
| makeParameterArray | back to summary |
|---|---|
| private static Type[] makeParameterArray(String descriptor) Helper for | |
| putIntern | back to summary |
|---|---|
| private static Prototype putIntern(Prototype desc) Puts the given instance in the intern table if it's not already there. If a conflicting value is already in the table, then leave it. Return the interned value. | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object. | |
| withFirstParameter | back to summary |
|---|---|
| public Prototype withFirstParameter(Type param) Returns a new interned instance, which is the same as this instance, except that it has an additional parameter prepended to the original's argument list. | |