Class Notification
java.lang.Object
io.jenkins.plugins.batchcontrol.ops.Notification
Immutable description of one notification (SPEC item 13, D-36), handed to every
BatchControlNotifier. All values are plain text; a notifier that renders HTML must
escape them.-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionNotification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url) Notification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url, String action) Notification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url, String action, List<String> details) Notification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url, String action, List<String> details, List<String> notices) -
Method Summary
Modifier and TypeMethodDescriptionACTIVATEorHOLDfor an activation request;nullfor other kinds.Plain-textLabel: valuelines describing what the request asks for (for a change request: actions, duration and name restriction); nevernull, possibly empty.getKind()"RUN"for a run request,"GRANT"for a change request or window,"ACTIVATION"for an activation or hold request.Plain-text sentences the recipient must notice, for example"The requester does not have Build permission on this job."(D-38a, run requests,REQUEST_CREATEDandAPPROVERS_CHANGED); nevernull, possibly empty.Jenkins user ids to notify; nevernull.The request id (for a window, the id of the change request it came from).The job full name (run, activation) or the scope full name (grant).getUrl()Absolute link to the request page from the configured Jenkins URL, ornullwhen none is configured.toString()
-
Field Details
-
Constructor Details
-
Notification
-
Notification
public Notification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url, String action) - Parameters:
action- for an activation request the requested action (ACTIVATEorHOLD, security-13 S-13-08);nullfor other kinds
-
Notification
public Notification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url, String action, List<String> details) - Parameters:
details- plain-text lines describing what is decided on, eachLabel: value(for a change request its actions, duration and name restriction, e2e-03 DEF-24);nullfor none
-
Notification
public Notification(String kind, String requestId, String subject, String requester, String reason, List<String> recipients, String url, String action, List<String> details, List<String> notices) - Parameters:
notices- plain-text sentences the approver must notice (D-38a: the requester does not have Build permission on the job);nullfor none
-
-
Method Details
-
getAction
ACTIVATEorHOLDfor an activation request;nullfor other kinds. -
getNotices
Plain-text sentences the recipient must notice, for example"The requester does not have Build permission on this job."(D-38a, run requests,REQUEST_CREATEDandAPPROVERS_CHANGED); nevernull, possibly empty. -
getDetails
Plain-textLabel: valuelines describing what the request asks for (for a change request: actions, duration and name restriction); nevernull, possibly empty. -
getKind
"RUN"for a run request,"GRANT"for a change request or window,"ACTIVATION"for an activation or hold request. -
getRequestId
The request id (for a window, the id of the change request it came from). -
getSubject
The job full name (run, activation) or the scope full name (grant). -
getRequester
-
getReason
-
getRecipients
Jenkins user ids to notify; nevernull. -
getUrl
Absolute link to the request page from the configured Jenkins URL, ornullwhen none is configured. -
toString
-