For some reason this is not working for me.
I created a custom component that accepts XML types and merges them together spitting back out a type that can be read into an XML type. I need to be able to have a variable number of XML variable so I thought a list would be appropriate. I can get the LIST type INT working and STRING. But not XML. Does anyone have any clue how I can get this working and/or create a variable number of XML types on the fly?
Views
Replies
Total Likes
Hi,
If I'm not wrong XML type extended from String type, so you can try to use List of String for your purpose.
At least in Workbench if you create varible type string you can easy store there xml, and get it back.
BR,
Paul Butenko
Views
Replies
Total Likes
The problem is that the XML type seems to keep the brackets and the XML structure in general where as the String type seems to throw it away. Either way though I cannot actually test that with a list of strings because for some silly reason i can't seem to simply assign the list the root node and have it do its thing.
Views
Replies
Total Likes
The XML object is a representation of the org.w3c.dom.Document object. Although LC can convert this to an string or a com.adobe.idp.Document object fairly easily, its still a w3c document under the covers.
Views
Replies
Total Likes
So the only question that is left is how I can have a dynamic list of these guys?
Views
Replies
Total Likes
import
com.adobe.idp.Document;
List<Document> list =
new ArrayList<Document>();
list
.add(xml);Hope this helps.
BR
Views
Replies
Total Likes
Thanks. I will give this a shot. I almost had things working with a map. But the problem was that the "Using XPath expressions as list indexes and map keys" help page is misleading because the funtion doesn't actually work. It will just return a null. When you put something into a string you must ommit the single quotations.
Views
Replies
Total Likes