: Is there a way to add attributes besides name to an xml node returned from
: SolrQueryResponse? I've looked at the SolrQueryResponse.add and it looks
: like a NamedList is my only option.  I know that I can get by with nodes
: that have only the name attribute but it would make life a little easier to
: throw some more attributes on a node.

FYI: The orriginal thinking behind the current XML format was that
itshould only contain concepts that were easy to map to the "primitive"
types found in most type safe langauges: int/float/date/string/etc...
<lst> exists to provide a simple mechanism to support both: Ordered lists
of heterogenously typed objects; and Un-Ordered name/value pairs  ... all
depending on what you prefer.

Allowing arbitrarry attributes would complicate that simple mapping of tag
to primitive object -- Which doesn't mean I'm opposed to the idea, I
acctually think it would be nice if there was a simple way to add a DOM
sub-trees directly to the response -- but I'd advocate not having any core
Solr code use this ... mainly because one of the "Near Term" goals is to
get an XML DTD/Schema that validates all legal responses from any (real or
theoretical) RequestHandler.  Allowing arbitrary XL attributes would
illiminate SolrCore's ability to ensure that the XML responses it
generates validate with that DTD/Schema -- so if we did add support for
it, we'd want to treat it special in some way.

-Hoss

Reply via email to