[T] AttributeDecorator
type AttributeDecorator = (context, target) => void;
Specify that the target property should be encoded as an XML attribute instead of node.
Parameters
Section titled “Parameters”Parameter | Type |
---|---|
context | DecoratorContext |
target | ModelProperty |
Returns
Section titled “Returns”void
Examples
Section titled “Examples”model Blob { id: string;}
<Blob> <id>abcdef</id></Blob>
model Blob { @attribute id: string;}
<Blob id="abcdef"></Blob>