Package org.apache.bookkeeper.bookie
Class DefaultFileChannel
- java.lang.Object
- 
- org.apache.bookkeeper.bookie.DefaultFileChannel
 
- 
- All Implemented Interfaces:
- BookieFileChannel
 
 class DefaultFileChannel extends java.lang.Object implements BookieFileChannel 
- 
- 
Constructor SummaryConstructors Constructor Description DefaultFileChannel(java.io.File file, ServerConfiguration serverConfiguration)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Close file channel and release all resources.booleanfileExists(java.io.File file)Check the given file if exists.java.io.FileDescriptorgetFD()Get the file descriptor of the opened file.java.nio.channels.FileChannelgetFileChannel()An interface for get the FileChannel from the provider.
 
- 
- 
- 
Constructor Detail- 
DefaultFileChannelDefaultFileChannel(java.io.File file, ServerConfiguration serverConfiguration) throws java.io.IOException- Throws:
- java.io.IOException
 
 
- 
 - 
Method Detail- 
getFileChannelpublic java.nio.channels.FileChannel getFileChannel() throws java.io.FileNotFoundExceptionDescription copied from interface:BookieFileChannelAn interface for get the FileChannel from the provider.- Specified by:
- getFileChannelin interface- BookieFileChannel
- Returns:
- Throws:
- java.io.FileNotFoundException
 
 - 
fileExistspublic boolean fileExists(java.io.File file) Description copied from interface:BookieFileChannelCheck the given file if exists.- Specified by:
- fileExistsin interface- BookieFileChannel
- Returns:
 
 - 
getFDpublic java.io.FileDescriptor getFD() throws java.io.IOExceptionDescription copied from interface:BookieFileChannelGet the file descriptor of the opened file.- Specified by:
- getFDin interface- BookieFileChannel
- Returns:
- Throws:
- java.io.IOException
 
 - 
closepublic void close() throws java.io.IOExceptionDescription copied from interface:BookieFileChannelClose file channel and release all resources.- Specified by:
- closein interface- BookieFileChannel
- Throws:
- java.io.IOException
 
 
- 
 
-