Show / Hide Table of Contents

Class AbstractNativeMarshaler

Base class for NativeMarshaler

Inheritance
System.Object
AbstractNativeMarshaler
CudaMarshaler
MainMemoryMarshaler
Implements
System.Runtime.InteropServices.ICustomMarshaler
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Hybridizer.Runtime.CUDAImports
Assembly: Hybridizer.Runtime.CUDAImports.dll
Syntax
public abstract class AbstractNativeMarshaler : ICustomMarshaler

Properties

cleanUpNativeData

cleans up native data

Declaration
public bool cleanUpNativeData { get; set; }
Property Value
Type Description
System.Boolean

CreatingThreadId

Declaration
public string CreatingThreadId { get; }
Property Value
Type Description
System.String

Flavor

current flavor

Declaration
public HybridizerFlavor Flavor { get; }
Property Value
Type Description
HybridizerFlavor

NbelementsInGhost

Returns the number of objects that have been marshaled

Declaration
public int NbelementsInGhost { get; }
Property Value
Type Description
System.Int32

Methods

AutoRegister(Assembly, Type)

Declaration
protected void AutoRegister(Assembly asm, Type marshallerType)
Parameters
Type Name Description
System.Reflection.Assembly asm
System.Type marshallerType

CleanUpManagedData(Object)

cleanup managed data

Declaration
public void CleanUpManagedData(object managedObj)
Parameters
Type Name Description
System.Object managedObj

CleanUpNativeData(IntPtr)

cleanup native data

Declaration
public void CleanUpNativeData(IntPtr pNativeData)
Parameters
Type Name Description
System.IntPtr pNativeData

CopyToSymbol(String, IntPtr, IntPtr, IntPtr, IntPtr)

copies memory to symbol

Declaration
public void CopyToSymbol(string targetSymbol, IntPtr src, IntPtr size, IntPtr offset, IntPtr module)
Parameters
Type Name Description
System.String targetSymbol
System.IntPtr src
System.IntPtr size
System.IntPtr offset
System.IntPtr module

Free()

Forces freeing all native allocated memory

Declaration
public void Free()

GetHandleDelegate(Delegate)

Declaration
public HandleDelegate GetHandleDelegate(Delegate deleg)
Parameters
Type Name Description
System.Delegate deleg
Returns
Type Description
HandleDelegate

GetNativeDataSize()

Get native data size

Declaration
public int GetNativeDataSize()
Returns
Type Description
System.Int32

IsClean()

Is state clean?

Declaration
public bool IsClean()
Returns
Type Description
System.Boolean

IsCleanUpNativeData()

is cleanup native data?

Declaration
public bool IsCleanUpNativeData()
Returns
Type Description
System.Boolean

MarshalManagedToNative(Object)

Marshals Managed to Native

Declaration
public virtual IntPtr MarshalManagedToNative(object managedObj)
Parameters
Type Name Description
System.Object managedObj
Returns
Type Description
System.IntPtr

MarshalNativeToManaged(IntPtr)

Marshals Native To Managed

Declaration
public object MarshalNativeToManaged(IntPtr pNativeData)
Parameters
Type Name Description
System.IntPtr pNativeData
Returns
Type Description
System.Object

RegisterDLL(String)

Register a dll that contains types to be used in marshaling

Declaration
public virtual bool RegisterDLL(string filename)
Parameters
Type Name Description
System.String filename
Returns
Type Description
System.Boolean

SetCustomMarshaler(Type, IHybCustomMarshaler)

sets a custom marshaler to a type

Declaration
public void SetCustomMarshaler(Type type, IHybCustomMarshaler cm)
Parameters
Type Name Description
System.Type type
IHybCustomMarshaler cm

Implements

System.Runtime.InteropServices.ICustomMarshaler
Back to top Generated by DocFX