Package org.opentrafficsim.core.egtf
Class Quantity<T extends Number,K>
- java.lang.Object
-
- org.opentrafficsim.core.egtf.Quantity<T,K>
-
- Type Parameters:
T
- data typeK
- grid output format
- Direct Known Subclasses:
TypedQuantity
public class Quantity<T extends Number,K> extends Object
Defines a quantity that data sources can provide, such as speed, flow, etc.Copyright (c) 2013-2022 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.- Version:
- $Revision$, $LastChangedDate$, by $Author$, initial version 24 okt. 2018
- Author:
- Wouter Schakel
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) K
convert(double[][] data)
Converts the filtered data to an output format.boolean
equals(Object obj)
String
getName()
Returns the name.int
hashCode()
(package private) boolean
isSpeed()
Returns whether this quantity is speed.static Quantity<?,double[][]>
si(String name)
Returns a quantity withdouble[][]
containing SI values as output format.String
toString()
-
-
-
Method Detail
-
si
public static Quantity<?,double[][]> si(String name)
Returns a quantity withdouble[][]
containing SI values as output format.- Parameters:
name
- String; name- Returns:
- quantity with
double[][]
containing SI values as output format
-
getName
public final String getName()
Returns the name.- Returns:
- String; name
-
isSpeed
final boolean isSpeed()
Returns whether this quantity is speed.- Returns:
- boolean; whether this quantity is speed
-
convert
final K convert(double[][] data)
Converts the filtered data to an output format.- Parameters:
data
- double[][]; filtered data- Returns:
- K; output data
-
-