質問

What is the best way to check if a string is valid XML for Jdom2?

役に立ちましたか?

解決

Put it in a try/catch block and parse it with JDOM 2..... then if you need to handle the JDOMException it is not valid.

rolfl

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top