Hi Mark,
Would it be a bridge too far to also factor out a generic BaseCollection
schema type?
See for example the changes on this branch:
http://bit.ly/generic-collections
The upside is that it makes it easy to write code that walks any of the
collection types, e.g.:
http://bit.ly/abstract-action
The downside is a slight loss of type-safety, in that it would be
theoretically possible to create a VMs instance that actually contains
some Host or DataCenter objects.
Also there's a slight bloat on the wire, as the resource elements are
decorated with a xsi:type attribute to indicate the actual resource
types:
http://www.pastie.org/937952
Cheers,
Eoghan
On Tue, 2010-04-27 at 19:40 +0100, Eoghan Glynn wrote:
On Tue, 2010-04-27 at 17:52 +0100, Mark McLoughlin wrote:
> Okay, I've pushed the changes to have the JAX-B classes generated from
> the schema
>
> I used both your <jaxb:property/> and <xs:extension/> tricks
Great! ... the BaseResource will make genericizing more of the CLI nice
and easy.
> I can't seem to get your cli working - I'll send you more details
> tomorrow, it's probably something stupid I'm doing
No worries, I've fixed the JAXB unmarshalling in the CLI client to make
it a bit more tolerant. All working again with the codegen'd model.
Cheers,
Eoghan
_______________________________________________
rhevm-api mailing list
rhevm-api(a)lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/rhevm-api