C# Class Mono.Cxxi.Abi.CppAbi

Show file Open project: kthompson/cxxi

Protected Properties

Property Type Description
cppip_dispose System.Reflection.MethodInfo
cppip_fromnative System.Reflection.ConstructorInfo
cppip_fromsize System.Reflection.ConstructorInfo
cppip_fromtype_managed System.Reflection.ConstructorInfo
cppip_managedalloc System.Reflection.MethodInfo
cppip_native System.Reflection.MethodInfo
cppip_tomanaged System.Reflection.MethodInfo
cppip_tomanaged_size System.Reflection.MethodInfo
cppobj_native System.Reflection.MethodInfo
intptr_zero System.Reflection.FieldInfo
marshal_offsetof System.Reflection.MethodInfo
marshal_ptrtostructure System.Reflection.MethodInfo
marshal_structuretoptr System.Reflection.MethodInfo
marshal_writeintptr System.Reflection.MethodInfo
notimplementedexception System.Reflection.ConstructorInfo
type_gettypefromhandle System.Reflection.MethodInfo
typeinfo_adjnative System.Reflection.MethodInfo
typeinfo_adjvcall System.Reflection.MethodInfo
typeinfo_fieldoffset System.Reflection.MethodInfo
typeinfo_nativesize System.Reflection.MethodInfo
typeinfo_vtable System.Reflection.MethodInfo
vtable_initinstance System.Reflection.MethodInfo
vtable_override_filter MemberFilter
vtable_resetinstance System.Reflection.MethodInfo
wrapper_to_typeinfo CppTypeInfo>.Dictionary

Public Methods

Method Description
GetCallingConvention ( MethodInfo methodInfo ) : CallingConvention?
GetMethodType ( CppTypeInfo typeInfo, MethodInfo imethod ) : MethodType
GetPInvokeSignature ( CppTypeInfo typeInfo, MethodInfo method ) : PInvokeSignature
GetVirtualMethodSlots ( CppTypeInfo typeInfo, Type interfaceType ) : IEnumerable
ImplementClass ( CppTypeInfo typeInfo ) : ICppClass
MakeTypeInfo ( CppLibrary lib, string typeName, Type interfaceType, Type layoutType, Type wrapperType ) : CppTypeInfo
ToPInvokeType ( Type t, ICustomAttributeProvider icap ) : Type

Protected Methods

Method Description
DefineImplType ( CppTypeInfo typeInfo ) : void
DefineMethod ( CppTypeInfo typeInfo, PInvokeSignature psig, int &vtableIndex ) : MethodBuilder
DefineProperty ( CppTypeInfo typeInfo, PropertyInfo property ) : PropertyBuilder
EmitCallVTableMethod ( CppTypeInfo typeInfo, MethodInfo method, int stackHeight, bool throwOnNoVTable ) : void
EmitCheckDisposed ( ILGenerator il, LocalBuilder native, MethodType methodType ) : void
EmitCheckManagedAlloc ( ILGenerator il, LocalBuilder cppip ) : void
EmitConstruct ( CppTypeInfo typeInfo, MethodInfo nativeMethod, PInvokeSignature psig, LocalBuilder cppInstancePtr, LocalBuilder nativePtr ) : void
EmitCreateCppObjectFromNative ( ILGenerator il, Type targetType, LocalBuilder cppip ) : void
EmitDestruct ( CppTypeInfo typeInfo, MethodInfo nativeMethod, PInvokeSignature psig, LocalBuilder cppInstancePtr, LocalBuilder nativePtr ) : void
EmitInboundMarshal ( ILGenerator il, Type nativeType, Type targetType ) : void
EmitInitVTable ( CppTypeInfo typeInfo, LocalBuilder cppip ) : void
EmitLoadInstancePtr ( ILGenerator il, CppTypeInfo typeInfo, bool isVirtual, Type firstParamType, LocalBuilder &cppip, LocalBuilder &native ) : void
EmitLoadVTable ( CppTypeInfo typeInfo ) : void
EmitManagedAlloc ( CppTypeInfo typeInfo, MethodInfo interfaceMethod ) : void
EmitNativeCall ( CppTypeInfo typeInfo, MethodInfo nativeMethod, PInvokeSignature psig, LocalBuilder nativePtr ) : void
EmitOutboundMarshal ( ILGenerator il, Type managedType, Type targetType ) : void
EmitPrepareVirtualCall ( CppTypeInfo typeInfo, LocalBuilder cppInstancePtr, int vtableIndex ) : MethodInfo
EmitResetVTable ( CppTypeInfo typeInfo, LocalBuilder cppip ) : void
FindManagedOverrideTarget ( Type wrapper, MethodInfo interfaceMethod ) : MethodInfo
GetMangledMethodName ( CppTypeInfo typeInfo, MethodInfo methodInfo ) : string
GetMangledVTableName ( CppTypeInfo typeInfo ) : string
GetMethodBuilder ( CppTypeInfo typeInfo, MethodInfo interfaceMethod ) : MethodBuilder
GetMethods ( Type interfaceType ) : IEnumerable
GetPInvokeForMethod ( CppTypeInfo typeInfo, PInvokeSignature sig ) : MethodBuilder
GetProperties ( Type interfaceType ) : IEnumerable
GetTypeInfo ( Type otherWrapperType ) : CppTypeInfo
ReturnByHiddenArgument ( CppTypeInfo typeInfo, MethodInfo method ) : bool

Private Methods

Method Description
GetManagedOverrideTrampoline ( CppTypeInfo typeInfo, int vtableIndex ) : Delegate

Method Details

DefineImplType() protected method

protected DefineImplType ( CppTypeInfo typeInfo ) : void
typeInfo CppTypeInfo
return void

DefineMethod() protected method

protected DefineMethod ( CppTypeInfo typeInfo, PInvokeSignature psig, int &vtableIndex ) : MethodBuilder
typeInfo CppTypeInfo
psig PInvokeSignature
vtableIndex int
return MethodBuilder

DefineProperty() protected method

protected DefineProperty ( CppTypeInfo typeInfo, PropertyInfo property ) : PropertyBuilder
typeInfo CppTypeInfo
property System.Reflection.PropertyInfo
return PropertyBuilder

EmitCallVTableMethod() protected method

protected EmitCallVTableMethod ( CppTypeInfo typeInfo, MethodInfo method, int stackHeight, bool throwOnNoVTable ) : void
typeInfo CppTypeInfo
method System.Reflection.MethodInfo
stackHeight int
throwOnNoVTable bool
return void

EmitCheckDisposed() protected method

protected EmitCheckDisposed ( ILGenerator il, LocalBuilder native, MethodType methodType ) : void
il ILGenerator
native LocalBuilder
methodType MethodType
return void

EmitCheckManagedAlloc() protected method

protected EmitCheckManagedAlloc ( ILGenerator il, LocalBuilder cppip ) : void
il ILGenerator
cppip LocalBuilder
return void

EmitConstruct() protected method

protected EmitConstruct ( CppTypeInfo typeInfo, MethodInfo nativeMethod, PInvokeSignature psig, LocalBuilder cppInstancePtr, LocalBuilder nativePtr ) : void
typeInfo CppTypeInfo
nativeMethod System.Reflection.MethodInfo
psig PInvokeSignature
cppInstancePtr LocalBuilder
nativePtr LocalBuilder
return void

EmitCreateCppObjectFromNative() protected method

protected EmitCreateCppObjectFromNative ( ILGenerator il, Type targetType, LocalBuilder cppip ) : void
il ILGenerator
targetType System.Type
cppip LocalBuilder
return void

EmitDestruct() protected method

protected EmitDestruct ( CppTypeInfo typeInfo, MethodInfo nativeMethod, PInvokeSignature psig, LocalBuilder cppInstancePtr, LocalBuilder nativePtr ) : void
typeInfo CppTypeInfo
nativeMethod System.Reflection.MethodInfo
psig PInvokeSignature
cppInstancePtr LocalBuilder
nativePtr LocalBuilder
return void

EmitInboundMarshal() protected method

protected EmitInboundMarshal ( ILGenerator il, Type nativeType, Type targetType ) : void
il ILGenerator
nativeType System.Type
targetType System.Type
return void

EmitInitVTable() protected method

protected EmitInitVTable ( CppTypeInfo typeInfo, LocalBuilder cppip ) : void
typeInfo CppTypeInfo
cppip LocalBuilder
return void

EmitLoadInstancePtr() protected method

protected EmitLoadInstancePtr ( ILGenerator il, CppTypeInfo typeInfo, bool isVirtual, Type firstParamType, LocalBuilder &cppip, LocalBuilder &native ) : void
il ILGenerator
typeInfo CppTypeInfo
isVirtual bool
firstParamType System.Type
cppip LocalBuilder
native LocalBuilder
return void

EmitLoadVTable() protected method

protected EmitLoadVTable ( CppTypeInfo typeInfo ) : void
typeInfo CppTypeInfo
return void

EmitManagedAlloc() protected method

protected EmitManagedAlloc ( CppTypeInfo typeInfo, MethodInfo interfaceMethod ) : void
typeInfo CppTypeInfo
interfaceMethod System.Reflection.MethodInfo
return void

EmitNativeCall() protected method

protected EmitNativeCall ( CppTypeInfo typeInfo, MethodInfo nativeMethod, PInvokeSignature psig, LocalBuilder nativePtr ) : void
typeInfo CppTypeInfo
nativeMethod System.Reflection.MethodInfo
psig PInvokeSignature
nativePtr LocalBuilder
return void

EmitOutboundMarshal() protected method

protected EmitOutboundMarshal ( ILGenerator il, Type managedType, Type targetType ) : void
il ILGenerator
managedType System.Type
targetType System.Type
return void

EmitPrepareVirtualCall() protected method

protected EmitPrepareVirtualCall ( CppTypeInfo typeInfo, LocalBuilder cppInstancePtr, int vtableIndex ) : MethodInfo
typeInfo CppTypeInfo
cppInstancePtr LocalBuilder
vtableIndex int
return System.Reflection.MethodInfo

EmitResetVTable() protected method

protected EmitResetVTable ( CppTypeInfo typeInfo, LocalBuilder cppip ) : void
typeInfo CppTypeInfo
cppip LocalBuilder
return void

FindManagedOverrideTarget() protected method

protected FindManagedOverrideTarget ( Type wrapper, MethodInfo interfaceMethod ) : MethodInfo
wrapper System.Type
interfaceMethod System.Reflection.MethodInfo
return System.Reflection.MethodInfo

GetCallingConvention() public abstract method

public abstract GetCallingConvention ( MethodInfo methodInfo ) : CallingConvention?
methodInfo System.Reflection.MethodInfo
return CallingConvention?

GetMangledMethodName() protected abstract method

protected abstract GetMangledMethodName ( CppTypeInfo typeInfo, MethodInfo methodInfo ) : string
typeInfo CppTypeInfo
methodInfo System.Reflection.MethodInfo
return string

GetMangledVTableName() protected method

protected GetMangledVTableName ( CppTypeInfo typeInfo ) : string
typeInfo CppTypeInfo
return string

GetMethodBuilder() protected method

protected GetMethodBuilder ( CppTypeInfo typeInfo, MethodInfo interfaceMethod ) : MethodBuilder
typeInfo CppTypeInfo
interfaceMethod System.Reflection.MethodInfo
return MethodBuilder

GetMethodType() public method

public GetMethodType ( CppTypeInfo typeInfo, MethodInfo imethod ) : MethodType
typeInfo CppTypeInfo
imethod System.Reflection.MethodInfo
return MethodType

GetMethods() protected method

protected GetMethods ( Type interfaceType ) : IEnumerable
interfaceType System.Type
return IEnumerable

GetPInvokeForMethod() protected method

protected GetPInvokeForMethod ( CppTypeInfo typeInfo, PInvokeSignature sig ) : MethodBuilder
typeInfo CppTypeInfo
sig PInvokeSignature
return MethodBuilder

GetPInvokeSignature() public method

public GetPInvokeSignature ( CppTypeInfo typeInfo, MethodInfo method ) : PInvokeSignature
typeInfo CppTypeInfo
method System.Reflection.MethodInfo
return PInvokeSignature

GetProperties() protected method

protected GetProperties ( Type interfaceType ) : IEnumerable
interfaceType System.Type
return IEnumerable

GetTypeInfo() protected method

protected GetTypeInfo ( Type otherWrapperType ) : CppTypeInfo
otherWrapperType System.Type
return CppTypeInfo

GetVirtualMethodSlots() public method

public GetVirtualMethodSlots ( CppTypeInfo typeInfo, Type interfaceType ) : IEnumerable
typeInfo CppTypeInfo
interfaceType System.Type
return IEnumerable

ImplementClass() public method

public ImplementClass ( CppTypeInfo typeInfo ) : ICppClass
typeInfo CppTypeInfo
return ICppClass

MakeTypeInfo() public method

public MakeTypeInfo ( CppLibrary lib, string typeName, Type interfaceType, Type layoutType, Type wrapperType ) : CppTypeInfo
lib CppLibrary
typeName string
interfaceType System.Type
layoutType System.Type
wrapperType System.Type
return CppTypeInfo

ReturnByHiddenArgument() protected method

protected ReturnByHiddenArgument ( CppTypeInfo typeInfo, MethodInfo method ) : bool
typeInfo CppTypeInfo
method System.Reflection.MethodInfo
return bool

ToPInvokeType() public method

public ToPInvokeType ( Type t, ICustomAttributeProvider icap ) : Type
t System.Type
icap ICustomAttributeProvider
return System.Type

Property Details

cppip_dispose protected static property

protected static MethodInfo,System.Reflection cppip_dispose
return System.Reflection.MethodInfo

cppip_fromnative protected static property

protected static ConstructorInfo,System.Reflection cppip_fromnative
return System.Reflection.ConstructorInfo

cppip_fromsize protected static property

protected static ConstructorInfo,System.Reflection cppip_fromsize
return System.Reflection.ConstructorInfo

cppip_fromtype_managed protected static property

protected static ConstructorInfo,System.Reflection cppip_fromtype_managed
return System.Reflection.ConstructorInfo

cppip_managedalloc protected static property

protected static MethodInfo,System.Reflection cppip_managedalloc
return System.Reflection.MethodInfo

cppip_native protected static property

protected static MethodInfo,System.Reflection cppip_native
return System.Reflection.MethodInfo

cppip_tomanaged protected static property

protected static MethodInfo,System.Reflection cppip_tomanaged
return System.Reflection.MethodInfo

cppip_tomanaged_size protected static property

protected static MethodInfo,System.Reflection cppip_tomanaged_size
return System.Reflection.MethodInfo

cppobj_native protected static property

protected static MethodInfo,System.Reflection cppobj_native
return System.Reflection.MethodInfo

intptr_zero protected static property

protected static FieldInfo,System.Reflection intptr_zero
return System.Reflection.FieldInfo

marshal_offsetof protected static property

protected static MethodInfo,System.Reflection marshal_offsetof
return System.Reflection.MethodInfo

marshal_ptrtostructure protected static property

protected static MethodInfo,System.Reflection marshal_ptrtostructure
return System.Reflection.MethodInfo

marshal_structuretoptr protected static property

protected static MethodInfo,System.Reflection marshal_structuretoptr
return System.Reflection.MethodInfo

marshal_writeintptr protected static property

protected static MethodInfo,System.Reflection marshal_writeintptr
return System.Reflection.MethodInfo

notimplementedexception protected static property

protected static ConstructorInfo,System.Reflection notimplementedexception
return System.Reflection.ConstructorInfo

type_gettypefromhandle protected static property

protected static MethodInfo,System.Reflection type_gettypefromhandle
return System.Reflection.MethodInfo

typeinfo_adjnative protected static property

protected static MethodInfo,System.Reflection typeinfo_adjnative
return System.Reflection.MethodInfo

typeinfo_adjvcall protected static property

protected static MethodInfo,System.Reflection typeinfo_adjvcall
return System.Reflection.MethodInfo

typeinfo_fieldoffset protected static property

protected static MethodInfo,System.Reflection typeinfo_fieldoffset
return System.Reflection.MethodInfo

typeinfo_nativesize protected static property

protected static MethodInfo,System.Reflection typeinfo_nativesize
return System.Reflection.MethodInfo

typeinfo_vtable protected static property

protected static MethodInfo,System.Reflection typeinfo_vtable
return System.Reflection.MethodInfo

vtable_initinstance protected static property

protected static MethodInfo,System.Reflection vtable_initinstance
return System.Reflection.MethodInfo

vtable_override_filter protected property

protected MemberFilter vtable_override_filter
return MemberFilter

vtable_resetinstance protected static property

protected static MethodInfo,System.Reflection vtable_resetinstance
return System.Reflection.MethodInfo

wrapper_to_typeinfo protected property

protected Dictionary wrapper_to_typeinfo
return CppTypeInfo>.Dictionary