Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

XML schema for GWT UIBinder

Tags:

gwt

uibinder

I'm wonderring whether Google is ready to publish (or there is at least any chance to "produce") the full formal xml schema for GWT UIBinder.

I've searched the latest entire GWT-SDK-2.4 distribution but found nothing. Does GWT simply look up java sources or reflect the classes of the widgets to validate the UIBinder xml counterparts, assuming that the xml schema was actually by no means predefined thus adopted to govern the validation?

@EDIT

According to the answer from @Ganesh Kumar, I've looked into ui.xsd (r6836) and found something e.g. in lines 496-499:

   <!--
        A complex type that contains both text and elements. There is no schema
        for the elements, they can be any elements.
    -->

There're also other similar occurrences indicating no schema for the elements alike. It seems that Google has not yet fully defined even agreed on the xml schema for UIBinder xml instances, doesn't it?

like image 212
sof Avatar asked Dec 31 '25 18:12

sof


1 Answers

AFAIK, the XSD is only there to help the Google Plugin for Eclipse doe autocomplete.

There's no schema per se, UiBinder generator directly matches the elements with classes and the attributes with setters (with a few exceptions, such as addStyleNames, this is documented in the UIObject javadoc). There are a bunch of element parsers specific to some widgets (each widget that uses one has some specific documentation in its javadoc), and there are attribute parsers to unmarshal attribute values into Java objects to pass to setters.

like image 90
Thomas Broyer Avatar answered Jan 06 '26 07:01

Thomas Broyer



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!