Methods Summary |
---|
protected final int | compareTo0(Constant other){@inheritDoc}
int cmp = super.compareTo0(other);
if (cmp != 0) {
return cmp;
}
CstBaseMethodRef otherMethod = (CstBaseMethodRef) other;
return prototype.compareTo(otherMethod.prototype);
|
public final int | getParameterWordCount(boolean isStatic)Gets the number of words of parameters required by this
method's descriptor. Since instances of this class have no way
to know if they will be used in a {@code static} or
instance context, one has to indicate this explicitly as an
argument. This method is just a convenient shorthand for
{@code getPrototype().getParameterTypes().getWordCount()},
plus {@code 1} if the method is to be treated as an
instance method.
return getPrototype(isStatic).getParameterTypes().getWordCount();
|
public final com.android.dx.rop.type.Prototype | getPrototype()Gets the raw prototype of this method. This doesn't include a
{@code this} argument.
return prototype;
|
public final com.android.dx.rop.type.Prototype | getPrototype(boolean isStatic)Gets the prototype of this method as either a
{@code static} or instance method. In the case of a
{@code static} method, this is the same as the raw
prototype. In the case of an instance method, this has an
appropriately-typed {@code this} argument as the first
one.
if (isStatic) {
return prototype;
} else {
if (instancePrototype == null) {
Type thisType = getDefiningClass().getClassType();
instancePrototype = prototype.withFirstParameter(thisType);
}
return instancePrototype;
}
|
public final com.android.dx.rop.type.Type | getType(){@inheritDoc}
In this case, this method returns the return type of this method.
return prototype.getReturnType();
|
public final boolean | isClassInit()Gets whether this is a reference to a class initialization
method. This is just a convenient shorthand for
{@code getNat().isClassInit()}.
return getNat().isClassInit();
|
public final boolean | isInstanceInit()Gets whether this is a reference to an instance initialization
method. This is just a convenient shorthand for
{@code getNat().isInstanceInit()}.
return getNat().isInstanceInit();
|