Parameter
Define a parameter to be used in class or interface method.
import { Parameter } from "@alloy-js/csharp";
<Parameter attributes={AttributesProp} default={Children} in name={string | Namekey} optional out ref refReadonly refkey={Refkey} type={Children} />import { Parameter } from "@alloy-js/csharp/stc";
Parameter({ attributes: AttributesProp, default: Children, in: boolean, name: string | Namekey, optional: boolean, out: boolean, ref: boolean, refReadonly: boolean, refkey: Refkey, type: Children,}).children(children)| attributes | optionalAttributesPropDefine attributes to attach |
| default | optionalChildrenDefault value for the parameter |
| in | optionalbooleanParameter modifier: The argument must be initialized before calling the method. The method can’t assign a new value to the parameter. The compiler might create a temporary variable to hold a copy of the argument to in parameters. |
| name | string | Namekey |
| optional | optionalbooleanIf the parmaeter is optional(without default value) |
| out | optionalbooleanParameter modifier: The calling method isn’t required to initialize the argument before calling the method. The method must assign a value to the parameter. |
| ref | optionalbooleanParameter modifier: The argument must be initialized before calling the method. The method can assign a new value to the parameter, but isn’t required to do so. |
| refReadonly | optionalbooleanParameter modifier: The argument must be initialized before calling the method. The method can’t assign a new value to the parameter. |
| refkey | optionalRefkey |
| type | Children |