public class DataFile extends LinkedNode<DataFile> implements Comparable<DataFile>
| Modifier and Type | Field and Description |
|---|---|
protected RecoverableRandomAccessFile |
appendRandomAccessFile |
protected SequenceSet |
corruptedBlocks |
protected Integer |
dataFileId |
protected File |
file |
protected int |
length |
static byte |
STANDARD_LOG_FILE |
protected int |
typeCode |
list, next, prev| Modifier and Type | Method and Description |
|---|---|
RecoverableRandomAccessFile |
appendRandomAccessFile() |
void |
closeRandomAccessFile(RecoverableRandomAccessFile file) |
int |
compareTo(DataFile df) |
void |
decrementLength(int size) |
boolean |
delete() |
boolean |
equals(Object o) |
SequenceSet |
getCorruptedBlocks() |
Integer |
getDataFileId() |
File |
getFile() |
int |
getLength() |
int |
getTypeCode() |
int |
hashCode() |
void |
incrementLength(int size) |
void |
move(File targetDirectory) |
RecoverableRandomAccessFile |
openRandomAccessFile() |
void |
setLength(int length) |
void |
setTypeCode(int typeCode) |
String |
toString() |
getHeadNode, getList, getNext, getNextCircular, getPrevious, getPreviousCircular, getTailNode, isHeadNode, isLinked, isTailNode, linkAfter, linkAfter, linkBefore, linkBefore, linkToHead, linkToTail, splitAfter, splitBefore, unlinkpublic static final byte STANDARD_LOG_FILE
protected final Integer dataFileId
protected volatile int length
protected int typeCode
protected final SequenceSet corruptedBlocks
protected RecoverableRandomAccessFile appendRandomAccessFile
public Integer getDataFileId()
public int getTypeCode()
public void setTypeCode(int typeCode)
public int getLength()
public void setLength(int length)
public void incrementLength(int size)
public void decrementLength(int size)
public RecoverableRandomAccessFile appendRandomAccessFile() throws IOException
IOExceptionpublic RecoverableRandomAccessFile openRandomAccessFile() throws IOException
IOExceptionpublic void closeRandomAccessFile(RecoverableRandomAccessFile file) throws IOException
IOExceptionpublic boolean delete() throws IOException
IOExceptionpublic void move(File targetDirectory) throws IOException
IOExceptionpublic SequenceSet getCorruptedBlocks()
public int compareTo(DataFile df)
compareTo in interface Comparable<DataFile>Copyright © 2005–2021 The Apache Software Foundation. All rights reserved.