android.databinding.tool.reflection
Class ModelMethod

java.lang.Object
  extended by android.databinding.tool.reflection.ModelMethod

public abstract class ModelMethod
extends java.lang.Object


Constructor Summary
ModelMethod()
           
 
Method Summary
 boolean acceptsArguments(java.util.List<ModelClass> args)
           
abstract  ModelClass getDeclaringClass()
           
static int getImplicitConversionLevel(ModelClass primitive)
           
abstract  java.lang.String getJniDescription()
          Returns the JNI description of the method which can be used to lookup it in SDK.
abstract  int getMinApi()
          Since when this method is available.
abstract  java.lang.String getName()
           
abstract  ModelClass[] getParameterTypes()
           
 ModelClass getReturnType()
           
abstract  ModelClass getReturnType(java.util.List<ModelClass> args)
           
abstract  boolean isAbstract()
           
 boolean isBetterArgMatchThan(ModelMethod other, java.util.List<ModelClass> args)
           
abstract  boolean isBindable()
           
static boolean isBoxingConversion(ModelClass class1, ModelClass class2)
           
static boolean isImplicitConversion(ModelClass from, ModelClass to)
           
abstract  boolean isPublic()
           
abstract  boolean isStatic()
           
abstract  boolean isVarArgs()
           
abstract  boolean isVoid()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ModelMethod

public ModelMethod()
Method Detail

getDeclaringClass

public abstract ModelClass getDeclaringClass()

getParameterTypes

public abstract ModelClass[] getParameterTypes()

getName

public abstract java.lang.String getName()

getReturnType

public abstract ModelClass getReturnType(java.util.List<ModelClass> args)

isVoid

public abstract boolean isVoid()

isPublic

public abstract boolean isPublic()

isStatic

public abstract boolean isStatic()

isAbstract

public abstract boolean isAbstract()

isBindable

public abstract boolean isBindable()
Returns:
whether or not this method has been given the Bindable annotation.

getMinApi

public abstract int getMinApi()
Since when this method is available. Important for Binding expressions so that we don't call non-existing APIs when setting UI.

Returns:
The SDK_INT where this method was added. If it is not a framework method, should return 1.

getJniDescription

public abstract java.lang.String getJniDescription()
Returns the JNI description of the method which can be used to lookup it in SDK.

See Also:
TypeUtil

isVarArgs

public abstract boolean isVarArgs()
Returns:
true if the final parameter is a varargs parameter.

acceptsArguments

public boolean acceptsArguments(java.util.List<ModelClass> args)
Parameters:
args - The arguments to the method
Returns:
Whether the arguments would be accepted as parameters to this method.

isBetterArgMatchThan

public boolean isBetterArgMatchThan(ModelMethod other,
                                    java.util.List<ModelClass> args)

getReturnType

public ModelClass getReturnType()

isBoxingConversion

public static boolean isBoxingConversion(ModelClass class1,
                                         ModelClass class2)

getImplicitConversionLevel

public static int getImplicitConversionLevel(ModelClass primitive)

isImplicitConversion

public static boolean isImplicitConversion(ModelClass from,
                                           ModelClass to)