I\'m new to Android and Java but do have some experience in Objective C and iPhone programming. I\'m attempting to recreate an app I\'ve already designed for the iPhone and
You should not make the Methods static.Because that is not an OOP Design then.
There are 2 ways:
1). Either make the properties public. (Not a good practise either)
2). add getters and setters for ParserHandler class
class ParserHandler {
private List dogArray = new ArrayList();
public List getDogArray() {
return this.dogArray;
}
public void setDogArray(List dogArray) {
this.dogArray = dogArray;
}
}
Now access dogArray Like this
ph.getDogArray();
int m = ph.getDogArray().size();
Initially it will be 0 since it is an empty list. Use the setter method to set the array first