InterfaceProperty
Render a C# interface property.
import { InterfaceProperty } from "@alloy-js/csharp";
<InterfaceProperty attributes={AttributesProp} doc={Children} file get internal name={string | Namekey} new nullable private protected public refkey={Refkey} set type={Children} />import { InterfaceProperty } from "@alloy-js/csharp/stc";
InterfaceProperty({ attributes: AttributesProp, doc: Children, file: boolean, get: boolean, internal: boolean, name: string | Namekey, new: boolean, nullable: boolean, private: boolean, protected: boolean, public: boolean, refkey: Refkey, set: boolean, type: Children,}).children(children)| attributes | optionalAttributesPropDefine attributes to attach |
| doc | optionalChildrenDoc comment |
| file | optionalboolean |
| get | optionalbooleanIf property should have a getter |
| internal | optionalboolean |
| name | string | Namekey |
| new | optionalboolean |
| nullable | optionalbooleanProperty initializer |
| private | optionalboolean |
| protected | optionalboolean |
| public | optionalboolean |
| refkey | optionalRefkey |
| set | optionalbooleanIf property should have a setter |
| type | ChildrenProperty type |
Example
Section titled “Example”<InterfaceProperty public name="My" get set />
public int My { get; set; };