Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/339.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/gwt/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java GWT ui活页夹:嵌套自定义小部件_Java_Gwt_Uibinder - Fatal编程技术网

Java GWT ui活页夹:嵌套自定义小部件

Java GWT ui活页夹:嵌套自定义小部件,java,gwt,uibinder,Java,Gwt,Uibinder,我有两个自定义小部件Foo-extends-Composite和Bar。我希望将它们嵌套在我的ui.xml中,如下所示: <my:Foo width="100%" ui:field="myFoo"> <my:Bar label="someLabel"/> </my:Foo> 我怎么能把这个修好?可以在ui.xml中嵌套我的自定义小部件吗?好的,我明白了:Foo也必须实现haswidget 你的Foo和Bar看起来怎么样?代码。与java示例(FooBar

我有两个自定义小部件
Foo-extends-Composite
Bar
。我希望将它们嵌套在我的ui.xml中,如下所示:

<my:Foo width="100%" ui:field="myFoo">
  <my:Bar label="someLabel"/>
</my:Foo>

我怎么能把这个修好?可以在ui.xml中嵌套我的自定义小部件吗?

好的,我明白了:
Foo
也必须实现
haswidget

你的
Foo
Bar
看起来怎么样?代码。与java示例(FooBar)保持良好的一致性。记住在Bar中声明@UiConstructor。
Found unexpected child element Element <my:Bar label='someLabel'>