Hi I am developing a application which I need to parse the xml data, for that I am taking a Vector to store the data instead of List as it supports in Java.How can I move the whole Class Stimulus stuff to the List in Blackberry.Here I attached the code that is in Java.I want to make it support to Blackberry.I would be greatful for any help..
public class Stimulus{
private Card card;
private List<Card> _cards = new ArrayList<Card>();
public void addCard(Card card){
this._cards.add(card);
}
public List<Card> getCards() {
return this._cards;
}
} And the code for class for Card is here
public class Card {
private String no;
private String text;
public String getNo() {
return no;
}
public void setNo(String no) {
this.no = no;
}
public String getText() {
return text;
}
public void setText(String text) {
this.text = text;
}
} The xml data is here
<stimulus name="Noun" type="0"><card><no>12</no><text><![CDATA[Evaluation Criteria]]></text></card></stimulus>
The above xmlcode is for sample.I have many card values in xml file. I want to find total card values for a particular stimulus.