Package jenkins.model
Class NodeListener
java.lang.Object
jenkins.model.NodeListener
- All Implemented Interfaces:
ExtensionPoint
Listen to
Node
CRUD operations.- Since:
- 2.8
- Author:
- ogondza.
-
Nested Class Summary
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic List<NodeListener>
all()
Get allNodeListener
s registered in Jenkins.protected boolean
Allows to veto node loading.static void
fireOnCreated
(Node node) Inform listeners that node is being created.static void
fireOnDeleted
(Node node) Inform listeners that node is being removed.static void
fireOnUpdated
(Node oldOne, Node newOne) Inform listeners that node is being updated.protected void
Node is being created.protected void
Node is being deleted.protected void
Node is being updated.
-
Constructor Details
-
NodeListener
public NodeListener()
-
-
Method Details
-
allowLoad
@Restricted(org.kohsuke.accmod.restrictions.Beta.class) protected boolean allowLoad(@NonNull Node node) Allows to veto node loading.- Parameters:
node
- the node being loaded. Not yet attached to Jenkins.- Returns:
- false to veto node loading.
-
onCreated
Node is being created. -
onUpdated
Node is being updated. -
onDeleted
Node is being deleted. -
fireOnCreated
Inform listeners that node is being created.- Parameters:
node
- A node being created.
-
fireOnUpdated
Inform listeners that node is being updated.- Parameters:
oldOne
- Old configuration.newOne
- New Configuration.
-
fireOnDeleted
Inform listeners that node is being removed.- Parameters:
node
- A node being removed.
-
all
Get allNodeListener
s registered in Jenkins.
-