• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Paul Clapham
  • Bear Bibeault
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • salvin francis
  • Scott Selikoff
  • fred rosenberger

Getting a file from datahandler

 
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I have a mime attachment part that contains a file created using ObjectOutputStream. How do I get the file out of the datahandler so that I can use Objectinputstream to read the objects?



Thanks.
[ August 22, 2006: Message edited by: Angela Truce ]
 
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have not yet checked if there is an easier way/api, but what i can think of now is: once you have the contents for the file, you can write that out to a, say, temp.ser file and then pass that temp.ser file to the ObjectInputStream. Is file creation on the local file system possible at your webservice client end?
 
Angela Truce
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I found a way to read the file! yay!

What I did was use the .getInputStream method and put this into the ObjectInputStream. The values were then read using the readObject method and then convert back to string array!

Thanks for the help anyway.
[ August 18, 2006: Message edited by: Angela Truce ]
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic