Which three statements about parsers are true? (Choose three.)
A.
SAX and StAX are bi-directional.
B.
DOM and StAX are bi-directional.
C.
StAX is a push API, whereas SAX is pull.
D.
SAX is a push API, whereas StAX is pull.
E.
SAX and StAX are read-only.
F.
SAX and DOM can write XML documents.
G.
StAX and DOM can write XML documents.
DOM: stored in memory, bi-directional
SAX: parser push event to user like startElement(…)
sTAX: user pull from parser like reader.hasNext then…
B, D And G Correct …..
https://docs.oracle.com/cd/E17802_01/webservices/webservices/docs/1.6/tutorial/doc/SJSXP2.html
https://docs.oracle.com/cd/E17802_01/webservices/webservices/docs/1.6/tutorial/doc/SJSXP2.html
above document shows StAX is forward only, why B is correct?
Comparing StAX to Other JAXP APIs