Package org.djutils.serialization
Class UnitSerializationTest
java.lang.Object
org.djutils.serialization.AbstractSerializationTest
org.djutils.serialization.UnitSerializationTest
UnitSerializationTest tests the encoding / decoding of values (Scalar, Vector, Matrix) with units.
Copyright (c) 2023-2025 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information https://djutils.org. The DJUTILS project is distributed under a three-clause BSD-style license, which can be found at https://djutils.org/docs/license.html.
- Author:
- Alexander Verbraeck
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidTest stored information about djunits display types.voidTest encoding and decoding of strongly typed quantities (DJUNITS).voidTest encoding and decoding of strongly typed quantities (DJUNITS).voidTest a double column matrix, where each column can contain a different quantity and/or display unit.voidTest a float column matrix, where each column can contain a different quantity and/or display unit.voidTest stored information about djunits SerializationUnits.voidTest exceptions with instantiation of unit column matrices.voidTest the UnitType class.Methods inherited from class org.djutils.serialization.AbstractSerializationTest
compare, deepEquals0, makePrimitive
-
Constructor Details
-
UnitSerializationTest
public UnitSerializationTest()
-
-
Method Details
-
testUnitType
Test the UnitType class. -
testDJunits
Test encoding and decoding of strongly typed quantities (DJUNITS).- Throws:
SerializationException- when that happens uncaught, this test has failedValueRuntimeException- when that happens uncaught, this test has failed
-
testDJunitsErrors
Test encoding and decoding of strongly typed quantities (DJUNITS).- Throws:
SerializationException- when that happens uncaught, this test has failedValueRuntimeException- when that happens uncaught, this test has failed
-
testSerializationUnits
Test stored information about djunits SerializationUnits.- Throws:
SerializationException- when that happens uncaught, this test has failedValueRuntimeException- when that happens uncaught, this test has failed
-
testDJunitDisplayTypes
Test stored information about djunits display types.- Throws:
SerializationException- when that happens uncaught, this test has failedValueRuntimeException- when that happens uncaught, this test has failed
-
testDoubleUnitColumnMatrix
Test a double column matrix, where each column can contain a different quantity and/or display unit.- Throws:
ValueRuntimeException- if that happens uncaught; this test has failedSerializationException- if that happens uncaught; this test has failed
-
testFloatUnitColumnMatrix
Test a float column matrix, where each column can contain a different quantity and/or display unit.- Throws:
ValueRuntimeException- if that happens uncaught; this test has failedSerializationException- if that happens uncaught; this test has failed
-
testUnitColumnMatrixExceptions
Test exceptions with instantiation of unit column matrices.
-