研究调查问卷:请告诉我们您使用 Blockly 的体验
开始调查问卷
blockly >输入 >输入 >removeField
从此输入中移除字段。
Signature:
removeField(name: string, opt_quiet?: boolean): boolean;
参数
参数 |
类型 |
说明 |
name |
字符串 |
字段的名称。 |
opt_quiet |
布尔值 |
(可选)为 true,以防止在字段不存在时发生错误。 |
返回:
布尔值
如果操作成功,则为 true;如果字段不存在且 opt_quiet 为 true,则为 false。
异常
如果该字段不存在且 opt_quiet 为 false,则会发生{错误}。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-09-11。
[null,null,["最后更新时间 (UTC):2024-09-11。"],[[["The `removeField` method removes a field, specified by its name, from a Blockly input."],["If `opt_quiet` is true, the method will not throw an error if the field is not found, but it will return `false`."],["If `opt_quiet` is false (or omitted) and the specified field is not found, the method will throw an error."],["This method is part of the `Blockly.inputs.Input` class, used for managing input fields within Blockly blocks."]]],[]]