net.sourceforge.combean.mathprog.linalg
Class DoubleVectorValue<Label>

Package class diagram package DoubleVectorValue
java.lang.Object
  extended by net.sourceforge.combean.mathprog.linalg.DoubleVectorValue<Label>
All Implemented Interfaces:
VectorValue<Label>
Direct Known Subclasses:
LPVectorValueImpl

public class DoubleVectorValue<Label>
extends Object
implements VectorValue<Label>

A simple implememtation of VectorValue consisting of a double value and and int index.


Constructor Summary
DoubleVectorValue(int index, double value)
           
DoubleVectorValue(int index, double value, Label label)
           
 
Method Summary
 double doubleValue()
          The value of the component.
 int index()
          The index of the component.
 Label label()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DoubleVectorValue

public DoubleVectorValue(int index,
                         double value)

DoubleVectorValue

public DoubleVectorValue(int index,
                         double value,
                         Label label)
Method Detail

doubleValue

public double doubleValue()
Description copied from interface: VectorValue
The value of the component.

Specified by:
doubleValue in interface VectorValue<Label>
Returns:
value

index

public int index()
Description copied from interface: VectorValue
The index of the component.

Specified by:
index in interface VectorValue<Label>
Returns:
index.

label

public Label label()
Specified by:
label in interface VectorValue<Label>
Returns:
a label which may carry arbitrary additional information about the component of the vector.