once you've got it in an object you can read the XML, however you won't be able to manipulate it. For that you may need to access the X3D XML through whatever plugin/method you're viewing X3D. Each plugin will probably have its own set of APIs.
Lemme know how you get on with this, I would be interested to know.
based off my experience and working with Plugins for unsupported browser filetypes (SVG, CGM, .3ko), I've had to resort to the proprietary APIs.
Which plugin are you using for X3D?