aspose file tools
The moose likes Java in General and the fly likes getting object but looking value in .data file Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "getting object but looking value in .data file" Watch "getting object but looking value in .data file" New topic
Author

getting object but looking value in .data file

Angus Ferguson
Ranch Hand

Joined: Jun 22, 2012
Posts: 240
Hi

I am reading from a file and setting the data in a List like this



When I retrieve the data I get the object definition instead of the value in the file. How could I get the value in the file?

Thanks
Steve Luke
Bartender

Joined: Jan 28, 2003
Posts: 3026
    
    4

Split returns an array. You will have to either choose which index in the array to add to your list, or iterate over the list to add them all, or convert the array to a List and use List.addAll(), like:


Steve
 
I agree. Here's the link: http://zeroturnaround.com/jrebel/download
 
subject: getting object but looking value in .data file
 
Similar Threads
How to pick up data in mysql with Java ?
Passing Jave object arrays
how to add every entry into a List as an Object
writing in and appending to a file
problem using generics jdk1.5 in jsp