NativeExport

The NativeExport aspect is a .NET-only attribute that can be used to export a .NET method as a .dll export. The attribute can only be applied to static methods on non generic classes and only in projects with an Architecture project setting of either x86 or x86_64 (i.e. not "AnyCpu", the default for .NET). Additionally it requires the "Allow Unsafe code" project setting to be enabled, as well.

The aspect has two optional parameters: * Name: String, to override the name of the dll export, by default this matches the method name. * CallingConvention: CallingConvention, this defines the calling convention. The default here is C-style stdcall.

[NativeExport('WriteLn')]
method WriteLine(aMessage: String);
begin
end;
[NativeExport('WriteLn')]
public void WriteLine(string message)
{
}
@NativeExport('WriteLn')
public func WriteLine(_ message: String!) {
}
@NativeExport('WriteLn')
public void WriteLine(string message)
{
}

Defined by the RemObjects.Elements.Cirrus dll.

Cocoa and Island Only

The Packed aspect is available on the .NET platform only.