|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--DSRG.VKB.QC
this class is needed to support the QC-Model. It contains the basic values to compute a QC-Value and the function to actually compute it. Currently the base values are hardcoded, that is soon to change.
Field Summary | |
private long |
CF_IO
the values for the cost dimensions |
private long |
CF_M
the values for the cost dimensions |
private long |
CF_T
the values for the cost dimensions |
private double |
cost_IO
the tradeoff parameters for the cost dimensions |
private double |
cost_M
the tradeoff parameters for the cost dimensions |
private double |
cost_T
the tradeoff parameters for the cost dimensions |
private double |
DD_attr
the degrees of divergence |
private double |
DD_ext
the degrees of divergence |
private static double |
maxCost
for normalization of the cost, I'll keep a maximum cost that is used in the computation of the complete value and is global for all QC-instances |
private double |
rho_attr
the trade-off parameters for the degrees of divergence |
private double |
rho_cost
the tradeoff parameters for the two dimensions |
private double |
rho_ext
the trade-off parameters for the degrees of divergence |
private double |
rho_quality
the tradeoff parameters for the two dimensions |
Constructor Summary | |
QC()
This is the testing constructor. |
|
QC(double my_rho_attr,
double my_rho_quality)
This constructor takes the preset values for the tradeoff factors. |
|
QC(double my_rho_attr,
double my_rho_quality,
double my_cost_M,
double my_cost_T,
double my_cost_IO)
This constructor takes the preset values for the tradeoff factors including the cost tradeoff factors ("unit costs"). |
Method Summary | |
private void |
computeOtherValues()
This method computes rho_cost and rho_ext from the other two tradeoff values |
long |
getCFIO()
returns the Number of I/O-Operations |
long |
getCFM()
returns the Number of Messages |
long |
getCFT()
returns the Number of Bytes Transferred |
double |
getCost()
gets the total cost by multiplying the costs with their cost factors and adding them. |
double |
getCostIO()
returns the tradeoff parameter ("unit cost") for the Number of I/O-Operations |
double |
getCostM()
returns the tradeoff parameter ("unit cost") for the Number of Messages |
double |
getCostT()
returns the tradeoff parameter ("unit cost") for the Number of Bytes Transferred |
double |
getDDattr()
returns the Degree of Divergence of the Attributes |
double |
getDDext()
returns the Degree of Divergence of the Extent |
double |
getQCValue()
compute the total QC-Value from the base values. |
double |
getQuality()
gets the total quality by multiplying the degrees of divergence with their tradeoff factors and adding them |
double |
getRhoAttr()
returns the tradeoff-parameter for the Degree of Divergence of the Attributes |
double |
getRhoCost()
returns the tradeoff-parameter for the total Cost |
double |
getRhoExt()
returns the tradeoff-parameter for the Degree of Divergence of the Extent |
double |
getRhoQuality()
returns the tradeoff-parameter for the total Degree of Divergence (Quality) |
protected boolean |
isQCValid()
checks if the tradeoff parameters are valid (i.e., the pairs add up to one) |
static void |
resetMaxCost()
resets the max.cost. |
boolean |
setCF(long myCF_M,
long myCF_T,
long myCF_IO)
sets the three cost factors at once. |
boolean |
setDD(double myDD_attr,
double myDD_ext)
sets the two Degrees of Divergence at once |
private void |
setRandomValues()
private method during testing to set some random QC-Values |
java.lang.String |
toString()
returns a string representation of the whole QC-object for testing purposes. |
Methods inherited from class java.lang.Object |
|
Field Detail |
private double DD_attr
private double DD_ext
private double rho_attr
private double rho_ext
private long CF_T
private long CF_M
private long CF_IO
private double cost_T
private double cost_M
private double cost_IO
private double rho_quality
private double rho_cost
private static double maxCost
Constructor Detail |
public QC()
public QC(double my_rho_attr, double my_rho_quality)
public QC(double my_rho_attr, double my_rho_quality, double my_cost_M, double my_cost_T, double my_cost_IO)
Method Detail |
private void computeOtherValues()
private void setRandomValues()
public double getQCValue()
public double getDDattr()
public double getDDext()
public boolean setDD(double myDD_attr, double myDD_ext)
public double getRhoAttr()
public double getRhoExt()
public long getCFM()
public long getCFT()
public long getCFIO()
public boolean setCF(long myCF_M, long myCF_T, long myCF_IO)
public double getCostM()
public double getCostT()
public double getCostIO()
public double getRhoQuality()
public double getRhoCost()
public double getCost()
public double getQuality()
protected boolean isQCValid()
public java.lang.String toString()
QC = 1- (0.3 * ( 0.4 *
0.85 + 0.6 * 0.9 ) + 0.7 * (0.0001 * 8000 + 0.0002 * 4000 +
0.0004 * 2500))
or QC = 1- (rho_quality * (
rho_attr * DD_attr + rho_ext * DD_ext ) + rho_cost * (cost_M *
CF_M + cost_T * CF_T + cost_IO * CF_IO))
public static void resetMaxCost()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |