Skip to content

Commit 04a3bde

Browse files
committed
add @throws clause and fix punctuation
Signed-off-by: Andrew Fitzgerald <[email protected]>
1 parent e9cfb59 commit 04a3bde

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

simpleclient/src/main/java/io/prometheus/client/Counter.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -143,10 +143,11 @@ public void inc(double amt) {
143143
* @param amt the amount to increment the counter by
144144
* @param exemplarLabels a set of key value pairs used to create the exemplar
145145
*
146-
* @throws IllegalArgumentException if exemplarLabels is null
147-
* @throws IllegalArgumentException if exemplarLabels does not contain an even number of values
148-
* @throws IllegalArgumentException if exemplarLabels contains any invalid labels
149-
* @throws IllegalArgumentException if the combined length of the exemplarLabels is greater than 64
146+
* @throws IllegalArgumentException If amt is negative.
147+
* @throws IllegalArgumentException if exemplarLabels is null.
148+
* @throws IllegalArgumentException if exemplarLabels does not contain an even number of values.
149+
* @throws IllegalArgumentException if exemplarLabels contains any invalid labels.
150+
* @throws IllegalArgumentException if the combined length of the exemplarLabels is greater than 64.
150151
*/
151152
public void incWithExemplar(double amt, String... exemplarLabels){
152153
//TODO exemplar label validation

simpleclient/src/main/java/io/prometheus/client/Histogram.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -274,10 +274,10 @@ public void observe(double amt) {
274274
* @param amt the amount to observe
275275
* @param exemplarLabels a set of key value pairs used to create the exemplar
276276
*
277-
* @throws IllegalArgumentException if exemplarLabels is null
278-
* @throws IllegalArgumentException if exemplarLabels does not contain an even number of values
279-
* @throws IllegalArgumentException if exemplarLabels contains any invalid labels
280-
* @throws IllegalArgumentException if the combined length of the exemplarLabels is greater than 64
277+
* @throws IllegalArgumentException if exemplarLabels is null.
278+
* @throws IllegalArgumentException if exemplarLabels does not contain an even number of values.
279+
* @throws IllegalArgumentException if exemplarLabels contains any invalid labels.
280+
* @throws IllegalArgumentException if the combined length of the exemplarLabels is greater than 64.
281281
*/
282282
public void observeWithExemplar(double amt, String... exemplarLabels) {
283283
//TODO exemplar label validation

0 commit comments

Comments
 (0)