Struct interoptopus_backend_csharp::Config[][src]

pub struct Config {
    pub file_header_comment: String,
    pub class: String,
    pub dll_name: String,
    pub namespace_mappings: NamespaceMappings,
    pub namespace_id: String,
    pub emit_rust_visibility: bool,
    pub unroll_struct_arrays: bool,
    pub write_global_types: bool,
    pub debug: bool,
}
Expand description

Configures C# code generation.

Fields

file_header_comment: String

The file header, e.g., // (c) My Company.

class: String

Static class for Interop methods, e.g., Interop.

dll_name: String

DLL to load, e.g., my_library.

namespace_mappings: NamespaceMappings

Maps which namespace id belongs into which FQN (e.g., “common” => “MyCompany.Common”).

namespace_id: String

Namespace ID of this namespace to write (default “”).

emit_rust_visibility: bool

Whether Visibility information should be honored.

unroll_struct_arrays: bool

Whether, say, a x: [u8; 3] should become 3 x0: u8, ... instead.

If this is not set, interop generation with arrays in structr will fail. This is a somewhat open issue w.r.t Unity-sans-unsafe support and feedback would be greatly welcome!

write_global_types: bool

Write types defined in Interoptopus.

debug: bool

Also generate markers for easier debugging

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.