|
||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
java.lang.Objectorg.maachang.jni.io.NativeRandomIO
org.maachang.jni.io.NativeFastRandomIO
public class NativeFastRandomIO
NativeRandomI/O(FAST).
このバッファは、速度重視を考慮した、チェック処理なしで、 Nativeファイルにアクセスするオブジェクトです. 欠点として、ダイレクトにNativeファイルにアクセスするので、 このオブジェクトによって操作した結果によって、処理異常が 発生した場合、最悪JavaVMが異常停止してしまいます.
フィールドの概要 |
---|
クラス org.maachang.jni.io.NativeRandomIO から継承されたフィールド |
---|
OPT_READ, OPT_WRITE |
コンストラクタの概要 | |
---|---|
NativeFastRandomIO(int opt,
java.lang.String name)
コンストラクタ. |
メソッドの概要 | |
---|---|
void |
close()
クローズ処理. |
void |
fsync()
ファイルキャッシュ強制出力. |
java.lang.String |
getName()
オープンファイル名を取得. |
int |
getOption()
ファイルオプションを取得. |
long |
getSeek()
現在のシーク位置を取得. |
boolean |
isOpen()
ファイルがオープン中かチェック. |
long |
length()
現在のファイルサイズを取得. |
void |
length(long length)
ファイルサイズを設定. |
int |
read(NativeBuffer buffer,
int offset,
int length)
読み込み処理. |
int |
read(NativeBuffer buffer,
long seek,
int offset,
int length)
読み込み処理. |
void |
write(NativeBuffer buffer,
int offset,
int length)
書込み処理. |
void |
write(NativeBuffer buffer,
long seek,
int offset,
int length)
書込み処理. |
クラス org.maachang.jni.io.NativeRandomIO から継承されたメソッド |
---|
createMemory, createMmap, createMmap, getPageFileLength, getPageFileShift |
クラス java.lang.Object から継承されたメソッド |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
コンストラクタの詳細 |
---|
public NativeFastRandomIO(int opt, java.lang.String name) throws java.lang.Exception
opt
- ファイルアクセスオプションを設定します.name
- 対象のファイル名を設定します.
java.lang.Exception
- 例外.メソッドの詳細 |
---|
public void close()
NativeRandomIO
内の close
public void fsync() throws java.lang.Exception
NativeRandomIO
内の fsync
java.lang.Exception
- 例外.public int read(NativeBuffer buffer, int offset, int length) throws java.lang.Exception
NativeRandomIO
内の read
buffer
- 読み込み先NativeBufferを設定します.offset
- 読み込みオフセット値を設定します.length
- 読み込みデータ長を設定します.
java.lang.Exception
- 例外.public int read(NativeBuffer buffer, long seek, int offset, int length) throws java.lang.Exception
NativeRandomIO
内の read
buffer
- 読み込み先NativeBufferを設定します.seek
- シーク位置を設定します.offset
- 読み込みオフセット値を設定します.length
- 読み込みデータ長を設定します.
java.lang.Exception
- 例外.public void write(NativeBuffer buffer, int offset, int length) throws java.lang.Exception
NativeRandomIO
内の write
buffer
- 書き込み先NativeBufferを設定します.offset
- 書込みオフセット値を設定します.length
- 書込みデータ長を設定します.
java.lang.Exception
- 例外.public void write(NativeBuffer buffer, long seek, int offset, int length) throws java.lang.Exception
NativeRandomIO
内の write
buffer
- 書き込み先NativeBufferを設定します.seek
- シーク位置を設定します.offset
- 書込みオフセット値を設定します.length
- 書込みデータ長を設定します.
java.lang.Exception
- 例外.public long getSeek() throws java.lang.Exception
NativeRandomIO
内の getSeek
java.lang.Exception
- 例外.public long length() throws java.lang.Exception
NativeRandomIO
内の length
java.lang.Exception
- 例外.public void length(long length) throws java.lang.Exception
NativeRandomIO
内の length
length
- ファイルサイズを設定します.
java.lang.Exception
- 例外.public java.lang.String getName()
NativeRandomIO
内の getName
public int getOption()
NativeRandomIO
内の getOption
public boolean isOpen()
NativeRandomIO
内の isOpen
|
||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |