edu.rice.cs.drjava.model
Class DummyDocumentRegion
java.lang.Object
edu.rice.cs.drjava.model.DummyDocumentRegion
- All Implemented Interfaces:
- FileRegion, Region
public class DummyDocumentRegion
- extends Object
- implements FileRegion
The concrete class for "dummy document" regions produced by ProjectFileParser. These degenerate regions, which do
not include a document, are only used transiently during project file input processing.
- Version:
- $Id$
Constructor Summary |
DummyDocumentRegion(File file,
int so,
int eo)
Create a new dummy document region (dummy because no document yet exists) |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_file
protected final File _file
_startOffset
protected volatile int _startOffset
_endOffset
protected volatile int _endOffset
DummyDocumentRegion
public DummyDocumentRegion(File file,
int so,
int eo)
- Create a new dummy document region (dummy because no document yet exists)
- Parameters:
file
- file that contains the regionso
- start offset of the region; if doc is non-null, then a Position will be created that moves within the documenteo
- end offset of the region; if doc is non-null, then a Position will be created that moves within the document
getFile
public File getFile()
- Specified by:
getFile
in interface FileRegion
- Returns:
- the file
getStartOffset
public int getStartOffset()
- Specified by:
getStartOffset
in interface FileRegion
- Specified by:
getStartOffset
in interface Region
- Returns:
- the start offset
getEndOffset
public int getEndOffset()
- Specified by:
getEndOffset
in interface FileRegion
- Specified by:
getEndOffset
in interface Region
- Returns:
- the end offset