public final class DefaultMethodFactory extends MethodFactory
| Modifier and Type | Class and Description |
|---|---|
private static class |
DefaultMethodFactory.BaseInvoker |
private static class |
DefaultMethodFactory.BooleanInvoker
Invokes the native function with a boolean return value.
|
(package private) static class |
DefaultMethodFactory.BooleanMarshaller
Converts a ruby Boolean into an 32 bit native integer.
|
(package private) static class |
DefaultMethodFactory.BufferMarshaller
Converts a ruby Buffer into a native address.
|
private static class |
DefaultMethodFactory.ConvertingInvoker
Invokes the native function, then passes the return value off to a
conversion method to massage it to a custom ruby type.
|
(package private) static class |
DefaultMethodFactory.ConvertingMarshaller |
private static class |
DefaultMethodFactory.Float32Invoker
Invokes the native function with a 32 bit float return value.
|
(package private) static class |
DefaultMethodFactory.Float32Marshaller
Converts a ruby Float into a 32 bit native float.
|
private static class |
DefaultMethodFactory.Float64Invoker
Invokes the native function with a 64 bit float return value.
|
(package private) static class |
DefaultMethodFactory.Float64Marshaller
Converts a ruby Float into a 64 bit native float.
|
(package private) static class |
DefaultMethodFactory.NonSessionMarshaller |
private static class |
DefaultMethodFactory.Pointer32Invoker
Invokes the native function with a native pointer return value.
|
private static class |
DefaultMethodFactory.Pointer64Invoker
Invokes the native function with a native pointer return value.
|
(package private) static class |
DefaultMethodFactory.PointerParameterMarshaller |
private static class |
DefaultMethodFactory.Signed16Invoker
Invokes the native function with n signed 8 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Signed16Marshaller
Converts a ruby Fixnum into a 16 bit native signed integer.
|
private static class |
DefaultMethodFactory.Signed32Invoker
Invokes the native function with a 32 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Signed32Marshaller
Converts a ruby Fixnum into a 32 bit native signed integer.
|
private static class |
DefaultMethodFactory.Signed64Invoker
Invokes the native function with a 64 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Signed64Marshaller
Converts a ruby Fixnum into a 64 bit native signed integer.
|
private static class |
DefaultMethodFactory.Signed8Invoker
Invokes the native function with n signed 8 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Signed8Marshaller
Converts a ruby Fixnum into an 8 bit native integer.
|
private static class |
DefaultMethodFactory.SingletonHolder |
private static class |
DefaultMethodFactory.StringInvoker
Invokes the native function with a native string return value.
|
(package private) static class |
DefaultMethodFactory.StringMarshaller
Converts a ruby String into a native pointer.
|
private static class |
DefaultMethodFactory.StructByValueInvoker
Invokes the native function with a native struct return value.
|
(package private) static class |
DefaultMethodFactory.StructByValueMarshaller
Converts a ruby String into a native pointer.
|
private static class |
DefaultMethodFactory.Unsigned16Invoker
Invokes the native function with an unsigned 32 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Unsigned16Marshaller
Converts a ruby Fixnum into a 16 bit native unsigned integer.
|
private static class |
DefaultMethodFactory.Unsigned32Invoker
Invokes the native function with an unsigned 32 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Unsigned32Marshaller
Converts a ruby Fixnum into a 32 bit native unsigned integer.
|
private static class |
DefaultMethodFactory.Unsigned64Invoker
Invokes the native function with a 64 bit unsigned integer return value.
|
(package private) static class |
DefaultMethodFactory.Unsigned64Marshaller
Converts a ruby Fixnum into a 64 bit native unsigned integer.
|
private static class |
DefaultMethodFactory.Unsigned8Invoker
Invokes the native function with an unsigned 8 bit integer return value.
|
(package private) static class |
DefaultMethodFactory.Unsigned8Marshaller
Converts a ruby Fixnum into an 8 bit native unsigned integer.
|
private static class |
DefaultMethodFactory.VoidInvoker
Invokes the native function with no return type, and returns nil to ruby.
|
| Modifier | Constructor and Description |
|---|---|
private |
DefaultMethodFactory() |
| Modifier and Type | Method and Description |
|---|---|
(package private) DynamicMethod |
createMethod(RubyModule module,
com.kenai.jffi.Function function,
Type returnType,
Type[] parameterTypes,
com.kenai.jffi.CallingConvention convention,
IRubyObject enums,
boolean ignoreError) |
(package private) static ParameterMarshaller |
getEnumMarshaller(Type type,
com.kenai.jffi.CallingConvention convention,
IRubyObject enums)
Gets a marshaller to convert from a ruby type to a native type.
|
static DefaultMethodFactory |
getFactory() |
(package private) static FunctionInvoker |
getFunctionInvoker(NativeType returnType) |
(package private) static FunctionInvoker |
getFunctionInvoker(Type returnType) |
(package private) static ParameterMarshaller |
getMarshaller(NativeType type)
Gets a marshaller to convert from a ruby type to a native type.
|
(package private) static ParameterMarshaller |
getMarshaller(Type type,
com.kenai.jffi.CallingConvention convention,
IRubyObject enums)
Gets a marshaller to convert from a ruby type to a native type.
|
(package private) boolean |
isSupported(Type returnType,
Type[] parameterTypes,
com.kenai.jffi.CallingConvention convention) |
createDynamicMethodpublic static DefaultMethodFactory getFactory()
boolean isSupported(Type returnType, Type[] parameterTypes, com.kenai.jffi.CallingConvention convention)
isSupported in class MethodFactoryDynamicMethod createMethod(RubyModule module, com.kenai.jffi.Function function, Type returnType, Type[] parameterTypes, com.kenai.jffi.CallingConvention convention, IRubyObject enums, boolean ignoreError)
createMethod in class MethodFactorystatic FunctionInvoker getFunctionInvoker(Type returnType)
static FunctionInvoker getFunctionInvoker(NativeType returnType)
static ParameterMarshaller getMarshaller(Type type, com.kenai.jffi.CallingConvention convention, IRubyObject enums)
type - The native type to convert to.static ParameterMarshaller getEnumMarshaller(Type type, com.kenai.jffi.CallingConvention convention, IRubyObject enums)
type - The native type to convert to.enums - The enum mapstatic ParameterMarshaller getMarshaller(NativeType type)
type - The native type to convert to.