It is theoretically possible to serialize a component hierarchy into BXML. The 
challenge would be handling includes, script, and define blocks, which are not 
intrinsically part of the UI. These elements would need to be attached to their 
associated objects somehow so that BXMLSerializer#writeObject() would know how 
to handle them.

On Jul 9, 2011, at 9:16 AM, SYSE | Edvin wrote:

> Den 09.07.2011 14:13, skrev Greg Brown:
>> OK, thanks for clarifying. I hadn't really considered it before, but I think 
>> I agree that serialization should be reciprocal. And yes, it does seem like 
>> mutating the input stream would violate that reciprocity (though, at the 
>> moment, BXMLSerializer does not support writeObject(), so it is sort of an 
>> academic issue).
> 
> Wonder if that would be a cool way to create a GUI-builder for Pivot - build 
> the GUI and save it with BXMLSerializer#writeObject :) Pivot has a giant 
> advantage to Swing in this respect, as almost all Swing GUI builders create 
> code that is hard/painful to maintain, or use some proprietary file format. 
> The BXML could however probably be created almost identical to what one would 
> write manually.

Reply via email to