Class MovedBlocks.Locations<L>
java.lang.Object
org.apache.hadoop.hdfs.server.balancer.MovedBlocks.Locations<L>
- Direct Known Subclasses:
Dispatcher.DBlock
- Enclosing class:
- MovedBlocks<L>
A class for keeping track of a block and its locations
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLocation(L loc) add a locationvoidclean block locationsorg.apache.hadoop.hdfs.protocol.BlockgetBlock()longbooleanisLocatedOn(L loc) toString()
-
Field Details
-
locations
The locations of the replicas of the block.
-
-
Constructor Details
-
Locations
public Locations(org.apache.hadoop.hdfs.protocol.Block block)
-
-
Method Details
-
clearLocations
public void clearLocations()clean block locations -
addLocation
add a location -
isLocatedOn
- Returns:
- if the block is located on the given location.
-
getLocations
- Returns:
- its locations
-
getBlock
public org.apache.hadoop.hdfs.protocol.Block getBlock() -
getNumBytes
public long getNumBytes() -
toString
-