Accessors and Mutators
Hello Preethi.
I assume that List is a class defined by you. In the definition of your list class add a accessor and mutator (get and set methods) to you data structure. For example:
|
Code:
|
class List{
private String[] data;
public String[] getData(){
return data;
}
public void setData(String[] data){
this.data = data;
}
} |
Now you should be able to access the data by using the dot notation:
|
Code:
|
String record = list.getData(); |
Hope this helped.
__________________
Eyes dwelling into the past are blind to what lies in the future.
Last edited by tim; 01-04-2008 at 01:00 PM.
|