summaryrefslogtreecommitdiff
path: root/src/main/java/sevenUnits/unit/UnitValue.java
diff options
context:
space:
mode:
authorAdrien Hopkins <adrien.p.hopkins@gmail.com>2025-06-04 19:45:37 -0500
committerAdrien Hopkins <adrien.p.hopkins@gmail.com>2025-06-04 19:45:37 -0500
commit79e1653caf5c30667877a158433cbcd766a135af (patch)
tree891527e7365bf78eab3722704c1f74e57fbbca7d /src/main/java/sevenUnits/unit/UnitValue.java
parentd80b80857e739eb32afd7625789944abd3afe376 (diff)
Add version numbers to all @since tags
Specifically, for every @since tag with a date, I added another that contains the correspending version. I did not add date @since tags to comments that do not have them, as that would be too tedious for what it's worth. These dates could still be found by using git bisect though.
Diffstat (limited to 'src/main/java/sevenUnits/unit/UnitValue.java')
-rw-r--r--src/main/java/sevenUnits/unit/UnitValue.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/sevenUnits/unit/UnitValue.java b/src/main/java/sevenUnits/unit/UnitValue.java
index 97b7e54..4003c17 100644
--- a/src/main/java/sevenUnits/unit/UnitValue.java
+++ b/src/main/java/sevenUnits/unit/UnitValue.java
@@ -29,6 +29,7 @@ import sevenUnits.utils.NameSymbol;
*
* @author Adrien Hopkins
* @since 2020-07-26
+ * @since v0.3.0
*/
public final class UnitValue {
/**
@@ -59,6 +60,7 @@ public final class UnitValue {
* @param other unit to try to convert to
* @return true if this value can be converted to {@code other}.
* @since 2020-10-01
+ * @since v0.3.0
*/
public final boolean canConvertTo(Unit other) {
return this.unit.canConvertTo(other);
@@ -84,6 +86,7 @@ public final class UnitValue {
* needed.
* @return this unit as a {@link LinearUnitValue}
* @since 2020-09-29
+ * @since v0.3.0
*/
public final LinearUnitValue convertToBase(NameSymbol ns) {
final LinearUnit base = LinearUnit.getBase(this.unit).withName(ns);
@@ -95,6 +98,7 @@ public final class UnitValue {
* @return a {@code LinearUnitValue} that is equivalent to this value. It
* will have zero uncertainty.
* @since 2020-09-29
+ * @since v0.3.0
*/
public final LinearUnitValue convertToLinear(LinearUnit newUnit) {
return LinearUnitValue.getExact(newUnit,
@@ -121,6 +125,7 @@ public final class UnitValue {
/**
* @return the unit
* @since 2020-09-29
+ * @since v0.3.0
*/
public final Unit getUnit() {
return this.unit;
@@ -129,6 +134,7 @@ public final class UnitValue {
/**
* @return the value
* @since 2020-09-29
+ * @since v0.3.0
*/
public final double getValue() {
return this.value;