blockdeviceapi.java
来自「纯java操作系统jnode,安装简单和操作简单的个人使用的Java操作系统」· Java 代码 · 共 50 行
JAVA
50 行
/**
* $Id: BlockDeviceAPI.java,v 1.1 2003/11/25 11:50:46 epr Exp $
*/
package org.jnode.driver.block;
import java.io.IOException;
import org.jnode.driver.DeviceAPI;
/**
* <description>
*
* @author epr
*/
public interface BlockDeviceAPI extends DeviceAPI {
/**
* Gets the total length in bytes
* @return long
* @throws IOException
*/
public abstract long getLength()
throws IOException;
/**
* Read a block of data
* @param devOffset
* @param dest
* @param destOffset
* @param length
* @throws IOException
*/
public abstract void read(long devOffset, byte[] dest, int destOffset, int length)
throws IOException;
/**
* Write a block of data
* @param devOffset
* @param src
* @param srcOffset
* @param length
* @throws IOException
*/
public abstract void write(long devOffset, byte[] src, int srcOffset, int length)
throws IOException;
public abstract void flush()
throws IOException;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?