You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by Neeraj Bajaj <Ne...@Sun.COM> on 2001/09/10 18:42:38 UTC

[xerces2] XSDHandler class

hi ,
	
	Just a thought...
	
It seems primary job of XSDHandler is to co-ordinate the construction 		
of a grammar object corresponding to a schema. i could see
that it is also doing the job of traversing the schema.
	
I can see nice separate *traverser* classes for different part of schema
I will suggest making one more class ,say, "SchemaTraverser"
for the purpose of what has been done in functions like
	
constructTrees(), traverseSchema() of XSDHandler.
	
traversing of schema , constructing trees can be done in 
SchemaTraverser class. XSDHandler:parserSchema() should delegate
the job of traversing schema to  SchemaTraverser.
	
XSDHandler should restrict its role to co-ordinate the construction
of grammar. Traversing schema and populating the info
about the schema should be done separately.It may also avoid 
XSDHandler to deal with all type of traversers. Also a class
which is dealing with Grammar, it need not to interact with
all types of traversers.
			
I haven't looked into finer details what all can be shifted in 
SchemaTraverser. but if anybody there likes this idea ,i am 
ready to spend some time on it.
	
	
regards

Neeraj Bajaj
---------------------
Sun Microsystems, inc.
Ph.91-80-2298989 x87425.



---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org