本文整理了Java中java.io.RandomAccessFile.flush
方法的一些代码示例,展示了RandomAccessFile.flush
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。RandomAccessFile.flush
方法的具体详情如下:
包路径:java.io.RandomAccessFile
类名称:RandomAccessFile
方法名:flush
暂无
代码示例来源:origin: libgdx/libgdx
public void close () throws IOException {
if (data != null) {
flush();
data = null;
}
}
代码示例来源:origin: libgdx/libgdx
public void close () throws IOException {
if (data != null) {
flush();
data = null;
}
}
代码示例来源:origin: libgdx/libgdx
public void flush () throws IOException {
file.flush();
}
代码示例来源:origin: libgdx/libgdx
public void flush () throws IOException {
file.flush();
}
代码示例来源:origin: libgdx/libgdx
public RandomAccessFile (File file, String mode) throws FileNotFoundException {
name = file.getCanonicalPath();
mode = mode.toLowerCase();
if (!mode.equals("r") && !mode.equals("rw")) {
throw new IllegalArgumentException("mode: '" + mode + "'");
}
writeable = mode.equals("rw");
if (file.exists()) {
data = atob(File.LocalStorage.getItem(name));
len = data.length();
} else if (writeable) {
data = "";
dirty = true;
try {
flush();
} catch (IOException e) {
throw new FileNotFoundException("" + e);
}
} else {
throw new FileNotFoundException(name);
}
}
代码示例来源:origin: libgdx/libgdx
public RandomAccessFile (File file, String mode) throws FileNotFoundException {
name = file.getCanonicalPath();
mode = mode.toLowerCase();
if (!mode.equals("r") && !mode.equals("rw")) {
throw new IllegalArgumentException("mode: '" + mode + "'");
}
writeable = mode.equals("rw");
if (file.exists()) {
data = atob(File.LocalStorage.getItem(name));
len = data.length();
} else if (writeable) {
data = "";
dirty = true;
try {
flush();
} catch (IOException e) {
throw new FileNotFoundException("" + e);
}
} else {
throw new FileNotFoundException(name);
}
}
代码示例来源:origin: thothbot/parallax
public void close () throws IOException {
if (data != null) {
flush();
data = null;
}
}
代码示例来源:origin: thothbot/parallax
public void flush () throws IOException {
file.flush();
}
代码示例来源:origin: thothbot/parallax
public RandomAccessFile (File file, String mode) throws FileNotFoundException {
name = file.getCanonicalPath();
mode = mode.toLowerCase();
if (!mode.equals("r") && !mode.equals("rw")) {
throw new IllegalArgumentException("mode: '" + mode + "'");
}
writeable = mode.equals("rw");
if (file.exists()) {
data = atob(File.LocalStorage.getItem(name));
len = data.length();
} else if (writeable) {
data = "";
dirty = true;
try {
flush();
} catch (IOException e) {
throw new FileNotFoundException("" + e);
}
} else {
throw new FileNotFoundException(name);
}
}
内容来源于网络,如有侵权,请联系作者删除!