Module jdk.nio.mapmode
Package jdk.nio.mapmode

# Class ExtendedMapMode

java.lang.Object
jdk.nio.mapmode.ExtendedMapMode

public class ExtendedMapMode extends Object
JDK-specific map modes.

Since:
  14
See Also:
  - `FileChannel.map(java.nio.channels.FileChannel.MapMode, long, long)`

## Field Summary

Fields
Modifier and Type
Field
Description
`static final FileChannel.MapMode`
`READ_ONLY_SYNC`
File mapping mode for a read-only mapping of a file backed by non-volatile RAM.
`static final FileChannel.MapMode`
`READ_WRITE_SYNC`
File mapping mode for a read-write mapping of a file backed by non-volatile RAM.

## Method Summary

### Methods declared in class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### READ_ONLY_SYNC

public static final FileChannel.MapMode READ_ONLY_SYNC
File mapping mode for a read-only mapping of a file backed by non-volatile RAM.

The map method throws UnsupportedOperationException when this map mode is used on an implementation that does not support it.

Implementation Note:
  On Linux, the `MAP_SYNC` and `MAP_SHARED_VALIDATE` flags are specified to `mmap` when mapping the file into memory.

### READ_WRITE_SYNC

public static final FileChannel.MapMode READ_WRITE_SYNC
File mapping mode for a read-write mapping of a file backed by non-volatile RAM. force operations on a buffer created with this mode will be performed using cache line writeback rather than proceeding via a file device flush.

The map method throws UnsupportedOperationException when this map mode is used on an implementation that does not support it.

Implementation Note:
  On Linux, the `MAP_SYNC` and `MAP_SHARED_VALIDATE` flags are specified to `mmap` when mapping the file into memory.