garydgregory commented on code in PR #1475:
URL: https://github.com/apache/commons-lang/pull/1475#discussion_r2465316488
##########
src/main/java/org/apache/commons/lang3/concurrent/TimedSemaphore.java:
##########
@@ -235,10 +249,18 @@ public static Builder builder() {
/** A flag whether shutdown() was called. */
private boolean shutdown; // @GuardedBy("this")
+ /** Fairness mode checker */
+ private final boolean fair;
+
+ /** Backing semaphore that enforces blocking and (optionally) FIFO
fairness. */
+ private final Semaphore semaphore;
+
Review Comment:
No need for 2 blank lines. One is plenty here.
##########
src/main/java/org/apache/commons/lang3/concurrent/TimedSemaphore.java:
##########
@@ -179,6 +181,17 @@ public Builder setTimeUnit(final TimeUnit timeUnit) {
this.timeUnit = timeUnit;
return this;
}
+
+ /**
+ * ADDED: Enables or disables FIFO fairness
Review Comment:
The javadoc for a setter should read: "Sets ...". You signify that a public
or protected API was added with the Javadoc `since` tag.
A sentence ends in a period: "Sets whether the instance is fair."
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]