I have consumed rest Webservice and I get a response in text format, I want to convert this response to java object in order to do some logic.
I have tried to parse the text to XML unfortunately, doesn't work.
Response from web service:
<html>
<title>rest response</title>
<body>
<a href="http://Xwebservice-urlXXX/XY111NWA1">XY111NWA1</a>
<a href="http://Xwebservice-urlXXX/XY112NWA1">XY112NWA1</a>
<a href="http://Xwebservice-urlXXX/XY113NWA1">XY113NWA1</a>
<a href="http://Xwebservice-urlXXX/XY114NWA1">XY114NWA1</a>
<a href="http://Xwebservice-urlXXX/XY115NWA1">XY115NWA1</a>
<a href="http://Xwebservice-urlXXX/XY116NWA1">XY116NWA1</a>
<a href="http://Xwebservice-urlXXX/XY117NWA1">XY117NWA1</a>
<a href="http://Xwebservice-urlXXX/XY118NWA1">XY118NWA1</a>
<a href="http://Xwebservice-urlXXX/XY119NWA1">XY119NWA1</a>
</body>
</html>
I expect the output to be in XML format so I can parse then to JAVA object, or get the date between tags and the result should be a java list as follows:
XY111NWA1
XY112NWA1
XY113NWA1
XY114NWA1
XY115NWA1
XY116NWA1
XY117NWA1
XY118NWA1
XY119NWA1