Class CachedSAMClass

java.lang.Object
org.codehaus.groovy.reflection.CachedClass
org.codehaus.groovy.reflection.stdclasses.CachedSAMClass

public class CachedSAMClass
extends CachedClass
  • Constructor Details

    • CachedSAMClass

      public CachedSAMClass​(Class klazz, ClassInfo classInfo)
  • Method Details

    • isAssignableFrom

      public boolean isAssignableFrom​(Class argument)
      Overrides:
      isAssignableFrom in class CachedClass
    • coerceToSAM

      public static Object coerceToSAM​(Closure argument, Method method, Class clazz)
    • coerceToSAM

      public static Object coerceToSAM​(Closure argument, Method method, Class clazz, boolean isInterface)
    • coerceArgument

      public Object coerceArgument​(Object argument)
      Overrides:
      coerceArgument in class CachedClass
    • getSAMMethod

      public static Method getSAMMethod​(Class<?> c)
      returns the abstract method from a SAM type, if it is a SAM type.
      Parameters:
      c - the SAM class
      Returns:
      null if nothing was found, the method otherwise