Next you need to assign static values to the name and type attributes of the field element. 接下来,需要为field元素的name和type属性分配静态值。
The static information includes the name, the unit, and description of the data. 静态信息包括名称、单元和数据描述。
First up is support for binding to static properties via the class name. 首先是支持通过类名与静态属性绑定。
The " Student " class is indicated on the diagram ( the box with the name " Student ") because the static message " isEligible ( name, studentNumber )" is sent to it. 因为向“Student”类发送静态消息“isEligible(name,studentNumber)”,所以在图中标名了该类(名称为“Student”的框)。
But this approach proves to be more static, since the class name is derived directly from the discriminator's value. 但是这个方法显然更死板,因为类名直接派生自discriminator的值。