aspose file tools
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes NX: Contractors - open/close database Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Reply Bookmark "NX: Contractors - open/close database" Watch "NX: Contractors - open/close database" New topic
Author

NX: Contractors - open/close database

Rick DeBay
Ranch Hand

Joined: Jul 11, 2003
Posts: 70
The interface DBAccess doesn't have any open() or close() methods. I'd like to implement close() so I can close the RandomAccessFile object I keep open during the life of the object that maps to the database file.
The open() is no big deal as the Data class which implements DBAccess can call open() from the constructor, but there is nowhere to call close() from.
Any ideas on cleaning things without waiting for the GC thread to get around to it?
Rick DeBay
Ranch Hand

Joined: Jul 11, 2003
Posts: 70
Never mind, the situation shouldn't be a problem. The only way there could be an issue is if the server or stand-alone client is restarted within the same JVM, and the way the programs are to be run will cause a new JVM to be created each time.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: NX: Contractors - open/close database
 
Similar Threads
Extending Data class or not
Does the lock associate session ID or customer ID?
Refreshing JTable at run time
About File close question
Data.close()