Package org.jboss.forge.roaster.model
Interface MethodHolder<O extends JavaType<O>>
-
- All Superinterfaces:
MemberHolder<O>
- All Known Subinterfaces:
EnumConstant.ReadBody<O>,EnumConstantSource.Body,JavaClass<O>,JavaClassSource,JavaEnum<O>,JavaEnumSource,JavaInterface<O>,JavaInterfaceSource,MethodHolderSource<O>,PropertyHolder<O>,PropertyHolderSource<O>
public interface MethodHolder<O extends JavaType<O>> extends MemberHolder<O>
Represents aJavaTypethat may declare methods.- Author:
- Lincoln Baxter, III
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Method<O,?>getMethod(String name)Return theMethodwith the given name and zero parameters; otherwise return null.Method<O,?>getMethod(String name, Class<?>... paramTypes)Return theMethodwith the given name and signature types; otherwise return null.Method<O,?>getMethod(String name, String... paramTypes)Return theMethodwith the given name and signature types; otherwise return null.List<? extends Method<O,?>>getMethods()Get aListof allMethods declared by thisMethodHolderinstance, if any; otherwise, return an emptyListbooleanhasMethod(Method<O,?> name)Return true if thisMethodHolderhas a method with the given name and zero parameters; otherwise return false.booleanhasMethodSignature(String name)Return true if thisMethodHolderhas a method with the given name and zero parameters; otherwise return false.booleanhasMethodSignature(String name, Class<?>... paramTypes)Return true if thisMethodHolderhas a method with the given name and signature types; otherwise return false.booleanhasMethodSignature(String name, String... paramTypes)Return true if thisMethodHolderhas a method with the given name and signature types; otherwise return false.booleanhasMethodSignature(Method<?,?> method)Return true if thisMethodHolderhas a method with signature matching the given method's signature.-
Methods inherited from interface org.jboss.forge.roaster.model.MemberHolder
getMembers
-
-
-
-
Method Detail
-
hasMethod
boolean hasMethod(Method<O,?> name)
Return true if thisMethodHolderhas a method with the given name and zero parameters; otherwise return false.
-
hasMethodSignature
boolean hasMethodSignature(Method<?,?> method)
Return true if thisMethodHolderhas a method with signature matching the given method's signature.
-
hasMethodSignature
boolean hasMethodSignature(String name)
Return true if thisMethodHolderhas a method with the given name and zero parameters; otherwise return false.
-
hasMethodSignature
boolean hasMethodSignature(String name, String... paramTypes)
Return true if thisMethodHolderhas a method with the given name and signature types; otherwise return false.
-
hasMethodSignature
boolean hasMethodSignature(String name, Class<?>... paramTypes)
Return true if thisMethodHolderhas a method with the given name and signature types; otherwise return false.
-
getMethod
Method<O,?> getMethod(String name)
Return theMethodwith the given name and zero parameters; otherwise return null.
-
getMethod
Method<O,?> getMethod(String name, String... paramTypes)
Return theMethodwith the given name and signature types; otherwise return null.
-
getMethod
Method<O,?> getMethod(String name, Class<?>... paramTypes)
Return theMethodwith the given name and signature types; otherwise return null.
-
-