Skip to content

Commit 29b18f7

Browse files
committed
Fix a few small typos in the API documentation
- Updated a UnitFormat.java comment to improve the grammar. - The unit times() method is nowadays named multiply().
1 parent 7a0db62 commit 29b18f7

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/main/java/javax/measure/Unit.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ public interface Unit<Q extends Quantity<Q>> {
155155
* this unit's dimension do not match. For example:
156156
*
157157
* <code>
158-
* {@literal Unit<Speed>} C = METRE.times(299792458).divide(SECOND).asType(Speed.class);
158+
* {@literal Unit<Speed>} C = METRE.multiply(299792458).divide(SECOND).asType(Speed.class);
159159
* </code>
160160
*
161161
* @param <T>
@@ -217,7 +217,7 @@ public interface Unit<Q extends Quantity<Q>> {
217217
*
218218
* <code>
219219
* {@literal Unit<Angle>} RADIAN = ONE.alternate("rad").asType(Angle.class);<br>
220-
* {@literal Unit<Force>} NEWTON = METRE.times(KILOGRAM).divide(SECOND.pow(2)).alternate("N").asType(Force.class);<br>
220+
* {@literal Unit<Force>} NEWTON = METRE.multiply(KILOGRAM).divide(SECOND.pow(2)).alternate("N").asType(Force.class);<br>
221221
* {@literal Unit<Pressure>} PASCAL = NEWTON.divide(METRE.pow(2)).alternate("Pa").asType(Pressure.class);<br>
222222
* </code>
223223
*

src/main/java/javax/measure/format/UnitFormat.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
*
3939
* <h4><a name="synchronization">Synchronization</a></h4>
4040
* <p>
41-
* Instances of this class are not required to be thread-safe. It is recommended to of separate format instances for each thread. If multiple threads
41+
* Instances of this class are not required to be thread-safe. It is recommended to use separate format instances for each thread. If multiple threads
4242
* access a format concurrently, it must be synchronized externally.
4343
* <p>
4444
*

0 commit comments

Comments
 (0)