InterfaceProperty
Render a C# interface property.
import { InterfaceProperty } from "@alloy-js/csharp";
<InterfaceProperty doc={Children} file get internal name="string" new nullable private protected public refkey={Refkey} set type={Children} />
import { InterfaceProperty } from "@alloy-js/csharp/stc";
InterfaceProperty({ doc: Children, file: boolean, get: boolean, internal: boolean, name: string, new: boolean, nullable: boolean, private: boolean, protected: boolean, public: boolean, refkey: Refkey, set: boolean, type: Children,}).children(children)
Props
doc | optionalChildren Doc comment |
file | optionalboolean |
get | optionalboolean If property should have a getter |
internal | optionalboolean |
name | string |
new | optionalboolean |
nullable | optionalboolean Property initializer |
private | optionalboolean |
protected | optionalboolean |
public | optionalboolean |
refkey | optionalRefkey |
set | optionalboolean If property should have a setter |
type | Children Property type |
Example
<InterfaceProperty public name="My" get set />
public int My { get; set; };