Class AbstractFastNumericMethodGenerator

java.lang.Object
jnr.ffi.provider.jffi.BaseMethodGenerator
jnr.ffi.provider.jffi.AbstractFastNumericMethodGenerator
All Implemented Interfaces:
MethodGenerator
Direct Known Subclasses:
FastIntMethodGenerator, FastLongMethodGenerator, FastNumericMethodGenerator

abstract class AbstractFastNumericMethodGenerator extends BaseMethodGenerator
  • Field Details

    • STRATEGY_ADDRESS_METHODS

      static final Map<Class<? extends com.kenai.jffi.ObjectParameterStrategy>,Method> STRATEGY_ADDRESS_METHODS
    • STRATEGY_PARAMETER_TYPES

      static final Map<Class,Class<? extends com.kenai.jffi.ObjectParameterStrategy>> STRATEGY_PARAMETER_TYPES
  • Constructor Details

    • AbstractFastNumericMethodGenerator

      AbstractFastNumericMethodGenerator()
  • Method Details

    • generate

      public void generate(AsmBuilder builder, SkinnyMethodAdapter mv, LocalVariableAllocator localVariableAllocator, com.kenai.jffi.CallContext callContext, ResultType resultType, ParameterType[] parameterTypes, boolean ignoreError)
      Specified by:
      generate in class BaseMethodGenerator
    • addStrategyParameterType

      private static void addStrategyParameterType(Map<Class<? extends com.kenai.jffi.ObjectParameterStrategy>,Method> map, Class<? extends com.kenai.jffi.ObjectParameterStrategy> strategyClass, Class parameterType)
    • hasPointerParameterStrategy

      static boolean hasPointerParameterStrategy(Class javaType)
    • emitParameterStrategyLookup

      static Class<? extends com.kenai.jffi.ObjectParameterStrategy> emitParameterStrategyLookup(SkinnyMethodAdapter mv, Class javaParameterType)
    • emitParameterStrategyAddress

      static void emitParameterStrategyAddress(SkinnyMethodAdapter mv, Class nativeIntType, Class<? extends com.kenai.jffi.ObjectParameterStrategy> strategyClass, LocalVariable strategy, LocalVariable parameter)
    • emitDirectCheck

      static int emitDirectCheck(SkinnyMethodAdapter mv, Class javaParameterClass, Class nativeIntType, LocalVariable parameter, LocalVariable objCount, int pointerCount)
    • getObjectParameterMethodName

      static String getObjectParameterMethodName(int parameterCount)
    • getObjectParameterMethodSignature

      static String getObjectParameterMethodSignature(int parameterCount, int pointerCount)
    • getInvokerMethodName

      abstract String getInvokerMethodName(ResultType resultType, ParameterType[] parameterTypes, boolean ignoreErrno)
    • getInvokerSignature

      abstract String getInvokerSignature(int parameterCount, Class nativeIntType)
    • getInvokerType

      abstract Class getInvokerType()