posted 20 years ago
Not quite right. It really depends on what you wanna do with the array. Do you wanna return an element value from the specific index? Or a fixed location everytime?
When you uses a setter method, where do you wanna set the new data into? A fixed position or an arbitrary position?
Usually, not always, setter methods have to take in a parameter, usually the data you wishes to assign to a variable. And a getter method has no arguments while returning the value that you're interested in obtaining.
Hope this helps.
SCJP 1.4 * SCWCD 1.4 * SCBCD 1.3 * SCJA 1.0 * TOGAF 8