public class MappedFile extends Object implements Closeable
| Modifier and Type | Field and Description |
|---|---|
static int |
MAP_PV |
static int |
MAP_RO |
static int |
MAP_RW |
| Constructor and Description |
|---|
MappedFile(long size) |
MappedFile(String name,
long size) |
MappedFile(String name,
long size,
int mode) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
DataStream |
dataStream(ByteOrder order) |
long |
getAddr() |
RandomAccessFile |
getFile() |
int |
getMode() |
long |
getSize() |
void |
makeReadonly() |
static long |
map(RandomAccessFile f,
int mode,
long start,
long size) |
void |
sync() |
static void |
unmap(long start,
long size) |
public static final int MAP_RO
public static final int MAP_RW
public static final int MAP_PV
public MappedFile(long size)
public MappedFile(String name, long size) throws IOException
IOExceptionpublic MappedFile(String name, long size, int mode) throws IOException
IOExceptionpublic void sync()
throws IOException
IOExceptionpublic void makeReadonly()
throws IOException
IOExceptionpublic void close()
close in interface Closeableclose in interface AutoCloseablepublic final RandomAccessFile getFile()
public final long getAddr()
public final long getSize()
public int getMode()
public DataStream dataStream(ByteOrder order)
public static long map(RandomAccessFile f, int mode, long start, long size) throws IOException
IOExceptionpublic static void unmap(long start,
long size)
Copyright © 2019. All rights reserved.