This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes NX: about nio Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "NX: about nio" Watch "NX: about nio" New topic
Author

NX: about nio

Bigwood Liu
Ranch Hand

Joined: Feb 26, 2003
Posts: 240
Hi,
I had never used nio before, and have some questions:
1.I map the data section of database into memory by fileChannel.map(), I saw someone use allocate() to allocate the buffer's capacity, I think the following is enough am I right? Why after I map the file, the isLoaded() return false? Whether the FileChannel will be closed at some time in the future? and how to?
2.I set the current position to the end of cache, and put a char, and
force(), but the length of the file stored in harddisk increased far more than one char, why?

Thank you first,
Regards,
Damu
 
Have you checked out Aspose?
 
subject: NX: about nio
 
It's not a secret anymore!