Here's a proposal for the nodeFactory: why not have it have a set of 
createTypeXNode(id) for the common node types?  This would eliminate the 
casts needed and make the create methods simpler. 

Since we have a reasonably bounded set of AST nodes we're actually going 
to be using (the max number driven from the spec's grammar), why not just 
define the factory to have creation methods for each type, plus one 
'fallback' createNode(id) method for future expansion or less-frequently 
used node types.

A minor point, but it could be a little bit faster and seems like it would 
make implementing the Xalan factory impl a little bit easier as well.  Or 
am I missing something fundamental here?

- Shane

Reply via email to