public class EndpointMethod
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
class |
EndpointMethod.ResolvedSignature
Adapter class to compare
EndpointMethod instances based on their Java method signature
rather than the actual method implementation. |
| Modifier and Type | Method and Description |
|---|---|
static EndpointMethod |
create(java.lang.Class<?> endpointClass,
java.lang.reflect.Method method)
Creates an
EndpointMethod using type information directly available from the method's
declaring class. |
static EndpointMethod |
create(java.lang.Class<?> endpointClass,
java.lang.reflect.Method method,
com.google.common.reflect.TypeToken<?> declaringClass)
Creates an
EndpointMethod using type information from the given TypeToken. |
boolean |
equals(java.lang.Object o) |
static java.lang.Class<?> |
getClassFromType(java.lang.reflect.Type type)
Returns the class associated with
type. |
java.lang.Class<?> |
getEndpointClass()
Returns the endpoint class.
|
java.lang.reflect.Method |
getMethod()
Returns the underlying method object.
|
java.lang.Class<?>[] |
getParameterClasses()
Returns the parameter classes of the method.
|
java.util.List<java.lang.String> |
getParameterNames() |
com.google.common.reflect.TypeToken<?>[] |
getParameterTypes()
Returns the parameter types of the method.
|
EndpointMethod.ResolvedSignature |
getResolvedMethodSignature() |
com.google.common.reflect.TypeToken<?> |
getReturnType()
Returns the return type of the method.
|
int |
hashCode() |
void |
setParameterNames(java.util.List<java.lang.String> parameterNames) |
java.lang.String |
toString() |
public static java.lang.Class<?> getClassFromType(java.lang.reflect.Type type)
type. If this is a parameterized type or generic
array, then its raw or component type, respectively, will be returned. Null is returned
if type is not implemented by a Class<?>, ParameterizedType, or
GenericArrayType object.public java.lang.Class<?> getEndpointClass()
public java.lang.reflect.Method getMethod()
public com.google.common.reflect.TypeToken<?> getReturnType()
public com.google.common.reflect.TypeToken<?>[] getParameterTypes()
public java.lang.Class<?>[] getParameterClasses()
public static EndpointMethod create(java.lang.Class<?> endpointClass, java.lang.reflect.Method method, com.google.common.reflect.TypeToken<?> declaringClass)
EndpointMethod using type information from the given TypeToken.method - Must not have wildcard types (all generic types must be resolvable to a concrete
type using the given TypeToken).declaringClass - A token for the method's declaring class.public static EndpointMethod create(java.lang.Class<?> endpointClass, java.lang.reflect.Method method)
EndpointMethod using type information directly available from the method's
declaring class.method - Must not have wildcard types (all generic types must be resolvable to a concrete
type using type information from the method's declaring class).public EndpointMethod.ResolvedSignature getResolvedMethodSignature()
public boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.util.List<java.lang.String> getParameterNames()
public void setParameterNames(java.util.List<java.lang.String> parameterNames)