public class DiskBalancerVolume
extends java.lang.Object
| Constructor | Description |
|---|---|
DiskBalancerVolume() |
Constructs DiskBalancerVolume.
|
| Modifier and Type | Method | Description |
|---|---|---|
long |
computeEffectiveCapacity() |
Returns effective capacity of a volume.
|
float |
computeUsedPercentage() |
Returns the usedPercentage of a disk.
|
boolean |
equals(java.lang.Object o) |
Compares two volumes and decides if it is the same volume.
|
long |
getCapacity() |
Capacity of this volume.
|
double |
getFreeRatio() |
Get ratio between free space and capacity.
|
long |
getFreeSpace() |
Get free space of the volume.
|
java.lang.String |
getPath() |
Returns the path for this volume.
|
long |
getReserved() |
Gets the reserved size for this volume.
|
java.lang.String |
getStorageType() |
Gets the StorageType.
|
long |
getUsed() |
Gets the dfsUsed Size.
|
double |
getUsedRatio() |
Get ratio between used space and capacity.
|
java.lang.String |
getUuid() |
Gets the uuid for this volume.
|
double |
getVolumeDataDensity() |
Get this volume Data Density
Please see DiskBalancerVolumeSet#computeVolumeDataDensity to see how
this is computed.
|
int |
hashCode() |
Computes hash code for a diskBalancerVolume.
|
boolean |
isFailed() |
Indicates if this is a failed volume.
|
boolean |
isReadOnly() |
Tells us if this volume is read-only.
|
boolean |
isSkip() |
returns if we should skip this volume.
|
boolean |
isTransient() |
Indicates if the volume is Transient in nature.
|
static DiskBalancerVolume |
parseJson(java.lang.String json) |
Parses a Json string and converts to DiskBalancerVolume.
|
void |
setCapacity(long totalCapacity) |
Sets the capacity of this volume.
|
void |
setFailed(boolean fail) |
Sets the failed flag for this volume.
|
void |
setIsTransient(boolean transientValue) |
Tells us if a volume is transient.
|
void |
setPath(java.lang.String volPath) |
Sets the path for this volume.
|
void |
setReadOnly(boolean readOnly) |
Sets this volume as read only.
|
void |
setReserved(long reservedSize) |
Sets the reserved size.
|
void |
setSkip(boolean skipValue) |
Sets the Skip value for this volume.
|
void |
setStorageType(java.lang.String typeOfStorage) |
Sets the StorageType.
|
void |
setTransient(boolean aTransient) |
Sets volumes transient nature.
|
void |
setUsed(long dfsUsedSpace) |
Sets the used Space for Long.
|
void |
setUuid(java.lang.String id) |
Sets the uuid for this volume.
|
void |
setVolumeDataDensity(double volDataDensity) |
Sets this volume's data density.
|
java.lang.String |
toJson() |
returns a Json String.
|
public static DiskBalancerVolume parseJson(java.lang.String json) throws java.io.IOException
json - - Json Stringjava.io.IOExceptionpublic double getVolumeDataDensity()
public void setVolumeDataDensity(double volDataDensity)
volDataDensity - - densitypublic boolean isTransient()
public void setTransient(boolean aTransient)
aTransient - - boolpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objecto - Volume Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic long getCapacity()
public long getFreeSpace()
public double getUsedRatio()
public double getFreeRatio()
public void setCapacity(long totalCapacity)
totalCapacity - longpublic boolean isFailed()
public void setFailed(boolean fail)
fail - booleanpublic java.lang.String getPath()
public void setPath(java.lang.String volPath)
volPath - Pathpublic long getReserved()
public void setReserved(long reservedSize)
reservedSize - -- Sets the reserved.public java.lang.String getStorageType()
public void setStorageType(java.lang.String typeOfStorage)
typeOfStorage - - Storage Type String.public long getUsed()
public void setUsed(long dfsUsedSpace)
dfsUsedSpace - - dfsUsedSpace for this volume.public java.lang.String getUuid()
public void setUuid(java.lang.String id)
id - - Stringpublic long computeEffectiveCapacity()
public java.lang.String toJson()
throws java.io.IOException
java.io.IOExceptionpublic boolean isSkip()
public void setSkip(boolean skipValue)
skipValue - boolpublic float computeUsedPercentage()
public void setIsTransient(boolean transientValue)
transientValue - public boolean isReadOnly()
public void setReadOnly(boolean readOnly)
readOnly - - booleanCopyright © 2008–2025 Apache Software Foundation. All rights reserved.