Skip to content

Commit 96f6ed8

Browse files
Refactor comments for clarity in AdministrativeMonitor
1 parent 8b761a0 commit 96f6ed8

File tree

1 file changed

+10
-16
lines changed

1 file changed

+10
-16
lines changed

core/src/main/java/hudson/model/AdministrativeMonitor.java

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
* monitoring and activate/deactivate the monitor accordingly. Sometimes
5858
* this can be done by updating a flag from code (see {@link SCMTrigger}
5959
* for one such example), while other times it's more convenient to do
60-
* so by running some code periodically (for this, use {@link TimerTrigger#timer})
60+
* so by running some code periodically (for this, use {@link TimerTrigger#timer})
6161
*
6262
* <p>
6363
* {@link AdministrativeMonitor}s are bound to URL by {@link Jenkins#getAdministrativeMonitor(String)}.
@@ -94,8 +94,7 @@ public abstract class AdministrativeMonitor extends AbstractModelObject implemen
9494
private static final Logger LOGGER = Logger.getLogger(AdministrativeMonitor.class.getName());
9595

9696
/**
97-
* Human-readable ID of this monitor, which needs to be unique within the
98-
* system.
97+
* Human-readable ID of this monitor, which needs to be unique within the system.
9998
*
10099
* <p>
101100
* This ID is used to remember persisted setting for this monitor,
@@ -316,14 +315,10 @@ public Permission getRequiredPermission() {
316315
}
317316
318317
/**
319-
* Checks if the current user has the minimum required permission to view this
320-
* administrative monitor.
318+
* Checks if the current user has the minimum required permission to view this administrative monitor.
321319
* <p>
322-
* Subclasses may override this method and {@link #hasRequiredPermission()}
323-
* instead of {@link #getRequiredPermission()} to perform more complex
324-
* permission checks,
325-
* for example, checking either {@link Jenkins#MANAGE} or
326-
* {@link Jenkins#SYSTEM_READ}.
320+
* Subclasses may override this method and {@link #hasRequiredPermission()} instead of {@link #getRequiredPermission()} to perform more complex permission checks,
321+
* for example, checking either {@link Jenkins#MANAGE} or {@link Jenkins#SYSTEM_READ}.
327322
* </p>
328323
*
329324
* @see #getRequiredPermission()
@@ -334,7 +329,7 @@ public void checkRequiredPermission() {
334329
Jenkins.get().checkPermission(getRequiredPermission());
335330
}
336331

337-
/**
332+
/**
338333
* Checks if the current user has the minimum required permission to view this administrative monitor.
339334
* <p>
340335
* Subclasses may override this method and {@link #hasRequiredPermission()} instead of {@link #getRequiredPermission()} to perform more complex permission checks,
@@ -349,11 +344,10 @@ public boolean hasRequiredPermission() {
349344
return Jenkins.get().hasPermission(getRequiredPermission());
350345
}
351346

352-
/**
353-
* Checks if the current user has the minimum required permission to view this administrative monitor.
354-
* <p>
355-
* Subclasses may override this method and {@link #checkRequiredPermission} instead of {@link #getRequiredPermission()} to perform more complex permission checks,
356-
* for example, checking either {@link Jenkins#MANAGE} or {@link Jenkins#SYSTEM_READ}.
347+
/**
348+
* Checks if the current user has the minimum required permission to view any administrative monitor.
349+
*
350+
* @return true if the current user has the minimum required permission to view any administrative monitor.
357351
*
358352
* @since 2.468
359353
*/

0 commit comments

Comments
 (0)