U
- Unit of the vectorpublic interface WriteFloatVectorFunctions<U extends Unit<U>>
This file was generated by the OpenTrafficSim value classes generator, 09 mrt, 2015
Copyright (c) 2014 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
Modifier and Type | Method and Description |
---|---|
void |
normalize()
Normalize the vector, i.e.
|
void |
set(int index,
FloatScalar<U> value)
Replace the value at index by the supplied value which is in a compatible unit.
|
void |
setInUnit(int index,
float value,
U valueUnit)
Replace the value at index by the supplied value which is expressed in a supplied (compatible) unit.
|
void |
setSI(int index,
float valueSI)
Replace the value at index by the supplied value which is expressed in the standard SI unit.
|
void setSI(int index, float valueSI) throws ValueException
index
- int; index of the value to replacevalueSI
- float; the value to store (expressed in the standard SI unit)ValueException
- when index out of range (index < 0 or index >= size())void set(int index, FloatScalar<U> value) throws ValueException
index
- int; index of the value to replacevalue
- FloatScalar<U>; the strongly typed value to storeValueException
- when index out of range (index < 0 or index >= size())void setInUnit(int index, float value, U valueUnit) throws ValueException
index
- int; index of the value to replacevalue
- float; the value to store (which is expressed in valueUnit)valueUnit
- U; unit of the supplied valueValueException
- when index out of range (index < 0 or index >= size())void normalize() throws ValueException
ValueException
- when the sum of the values is zero and normalization is not possibleCopyright © 2014–2015 Delft University of Technology. All rights reserved.