Package org.apache.hadoop.hdfs.protocol
Class ErasureCodingPolicy
java.lang.Object
org.apache.hadoop.hdfs.protocol.ErasureCodingPolicy
- All Implemented Interfaces:
Serializable
A policy about how to write/read/code an erasure coding file.
Note this class should be lightweight and immutable, because it's cached
by SystemErasureCodingPolicies, to be returned as a part of
HdfsFileStatus.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionErasureCodingPolicy(String name, org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize, byte id) ErasureCodingPolicy(org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize) ErasureCodingPolicy(org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize, byte id) -
Method Summary
-
Constructor Details
-
ErasureCodingPolicy
public ErasureCodingPolicy(String name, org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize, byte id) -
ErasureCodingPolicy
public ErasureCodingPolicy(org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize, byte id) -
ErasureCodingPolicy
public ErasureCodingPolicy(org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize)
-
-
Method Details
-
composePolicyName
public static String composePolicyName(org.apache.hadoop.io.erasurecode.ECSchema schema, int cellSize) -
getName
-
getSchema
public org.apache.hadoop.io.erasurecode.ECSchema getSchema() -
getCellSize
public int getCellSize() -
getNumDataUnits
public int getNumDataUnits() -
getNumParityUnits
public int getNumParityUnits() -
getCodecName
-
getId
public byte getId() -
isReplicationPolicy
public boolean isReplicationPolicy() -
isSystemPolicy
public boolean isSystemPolicy() -
equals
-
hashCode
public int hashCode() -
toString
-