public class BlockIdentifier extends java.lang.Object implements java.lang.Comparable<BlockIdentifier>
Modifier and Type | Field and Description |
---|---|
private BlockType |
blockType |
private int |
index |
private int |
knownForeignReferences |
Constructor and Description |
---|
BlockIdentifier(int index,
BlockType blockType) |
Modifier and Type | Method and Description |
---|---|
void |
addForeignRef() |
static boolean |
blockIsOneOf(BlockIdentifier needle,
java.util.Set<BlockIdentifier> haystack) |
int |
compareTo(BlockIdentifier blockIdentifier) |
BlockType |
getBlockType() |
int |
getIndex() |
static BlockIdentifier |
getInnermostBreakable(java.util.List<BlockIdentifier> blocks) |
java.lang.String |
getName() |
static BlockIdentifier |
getOutermostContainedIn(java.util.Set<BlockIdentifier> endingBlocks,
java.util.Set<BlockIdentifier> blocksInAtThisPoint) |
static BlockIdentifier |
getOutermostEnding(java.util.List<BlockIdentifier> blocks,
java.util.Set<BlockIdentifier> blocksEnding) |
boolean |
hasForeignReferences() |
void |
releaseForeignRef() |
void |
setBlockType(BlockType blockType) |
java.lang.String |
toString() |
private final int index
private BlockType blockType
private int knownForeignReferences
public BlockIdentifier(int index, BlockType blockType)
public BlockType getBlockType()
public void setBlockType(BlockType blockType)
public java.lang.String getName()
public int getIndex()
public void addForeignRef()
public void releaseForeignRef()
public boolean hasForeignReferences()
public java.lang.String toString()
toString
in class java.lang.Object
public static boolean blockIsOneOf(BlockIdentifier needle, java.util.Set<BlockIdentifier> haystack)
public static BlockIdentifier getOutermostContainedIn(java.util.Set<BlockIdentifier> endingBlocks, java.util.Set<BlockIdentifier> blocksInAtThisPoint)
public static BlockIdentifier getInnermostBreakable(java.util.List<BlockIdentifier> blocks)
public static BlockIdentifier getOutermostEnding(java.util.List<BlockIdentifier> blocks, java.util.Set<BlockIdentifier> blocksEnding)
public int compareTo(BlockIdentifier blockIdentifier)
compareTo
in interface java.lang.Comparable<BlockIdentifier>