|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eigenbase.relopt.volcano.VolcanoCost
class VolcanoCost
VolcanoCost
represents the cost of a plan node.
This class is immutable: none of the methods (besides set(double, double, double)
)
modifies any member variables.
Field Summary | |
---|---|
(package private) double |
dCpu
|
(package private) double |
dIo
|
(package private) double |
dRows
|
(package private) static VolcanoCost |
HUGE
|
(package private) static VolcanoCost |
INFINITY
|
(package private) static VolcanoCost |
TINY
|
(package private) static VolcanoCost |
ZERO
|
Constructor Summary | |
---|---|
VolcanoCost(double dRows,
double dCpu,
double dIo)
|
Method Summary | |
---|---|
double |
divideBy(RelOptCost cost)
Computes the ratio between this cost and another cost. |
boolean |
equals(RelOptCost other)
Compares this to another cost. |
double |
getCpu()
|
double |
getIo()
|
double |
getRows()
|
boolean |
isEqWithEpsilon(RelOptCost other)
Compares this to another cost, allowing for slight roundoff errors. |
boolean |
isInfinite()
|
boolean |
isLe(RelOptCost other)
Compares this to another cost. |
boolean |
isLt(RelOptCost other)
Compares this to another cost. |
RelOptCost |
minus(RelOptCost other)
Subtracts another cost from this. |
RelOptCost |
multiplyBy(double factor)
Multiplies this cost by a scalar factor. |
RelOptCost |
plus(RelOptCost other)
Adds another cost to this. |
void |
set(double dRows,
double dCpu,
double dIo)
|
String |
toString()
Forces implementations to override Object.toString() and provide a
good cost rendering to use during tracing. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
static final VolcanoCost INFINITY
static final VolcanoCost HUGE
static final VolcanoCost ZERO
static final VolcanoCost TINY
double dCpu
double dIo
double dRows
Constructor Detail |
---|
VolcanoCost(double dRows, double dCpu, double dIo)
Method Detail |
---|
public double getCpu()
getCpu
in interface RelOptCost
public boolean isInfinite()
isInfinite
in interface RelOptCost
public double getIo()
getIo
in interface RelOptCost
public boolean isLe(RelOptCost other)
RelOptCost
isLe
in interface RelOptCost
other
- another cost
public boolean isLt(RelOptCost other)
RelOptCost
isLt
in interface RelOptCost
other
- another cost
public double getRows()
getRows
in interface RelOptCost
RelNode.getRows()
)public boolean equals(RelOptCost other)
RelOptCost
equals
in interface RelOptCost
other
- another cost
public boolean isEqWithEpsilon(RelOptCost other)
RelOptCost
isEqWithEpsilon
in interface RelOptCost
other
- another cost
public RelOptCost minus(RelOptCost other)
RelOptCost
minus
in interface RelOptCost
other
- another cost
public RelOptCost multiplyBy(double factor)
RelOptCost
multiplyBy
in interface RelOptCost
factor
- scalar factor
public double divideBy(RelOptCost cost)
RelOptCost
divideBy is the inverse of RelOptCost.multiplyBy(double)
. For any
finite, non-zero cost and factor f,
cost.divideBy(cost.multiplyBy(f))
yields 1 / f
.
divideBy
in interface RelOptCost
cost
- Other cost
public RelOptCost plus(RelOptCost other)
RelOptCost
plus
in interface RelOptCost
other
- another cost
public void set(double dRows, double dCpu, double dIo)
public String toString()
RelOptCost
Object.toString()
and provide a
good cost rendering to use during tracing.
toString
in interface RelOptCost
toString
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |