wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes Calling a method of an object stored in a TreeMap Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic
Author

Calling a method of an object stored in a TreeMap

Bob Bob
Greenhorn

Joined: Mar 20, 2003
Posts: 8
Im doing a project for my college class that requires me to write an applet that will create and store Employees Objects. I have written an Employee class containing a getName method used to return en employee's name. I have also created a required TreeMap collection (name empObjects) used to store the employee objects that will be made. My problem is, I need to find a statement that will allow me to get an object from my empObjects collection, call the getName method, and place it within a textbox (named empName). I have tried several times but cannot come up with a good solution. I would appreciate any help.
Michael Morris
Ranch Hand

Joined: Jan 30, 2002
Posts: 3451
Please do not post the same topic in multiple forums. I responded to this post here Using a class method of an object stored in a TreeMap .
Michael Morris


Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Ernst F. Schumacher
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Calling a method of an object stored in a TreeMap
 
Similar Threads
Using a class method of an object stored in a TreeMap
Iterator
question about treemaps
retrieving data from a TreeMap collection
A question About overriding equals and hashcode for an Object