简体   繁体   中英

How do I save an image, or text file for later use?

如何保存图像或文本文件以备后用?(编写和创建文件)

Use FileOutputStreams. Images should be written in binary mode.(DataOutput/InputStream) Search engines provide you several matches like: http://www.roseindia.net/java/example/java/io/java-write-to-file.shtml

You can take a look at this tutorial for writing to files and this tutorial for Java Serialization . You can also use Google to find tutorials about what you need to do.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM