@Restricted(value=org.kohsuke.accmod.restrictions.NoExternalUse.class) @Extension public static final class ListView.Listener extends ItemListener
ExtensionPoint.LegacyInstancesAreScopedToHudson| Constructor and Description |
|---|
Listener() |
| Modifier and Type | Method and Description |
|---|---|
void |
onDeleted(Item item)
Called right before a job is going to be deleted.
|
void |
onLocationChanged(Item item,
String oldFullName,
String newFullName)
Called after an item’s fully-qualified location has changed.
|
all, fireLocationChange, fireOnCopied, fireOnCreated, fireOnDeleted, fireOnUpdated, onBeforeShutdown, onCopied, onCreated, onLoaded, onRenamed, onUpdated, registerpublic void onLocationChanged(Item item, String oldFullName, String newFullName)
ItemListenerItemListener.onRenamed(hudson.model.Item, java.lang.String, java.lang.String) will already have been called on this item or an ancestor.
And where applicable, ItemListener.onLocationChanged(hudson.model.Item, java.lang.String, java.lang.String) will already have been called on its ancestors.
This method should be used (instead of ItemListener.onRenamed(hudson.model.Item, java.lang.String, java.lang.String)) by any code
which seeks to keep (absolute) references to items up to date:
if a persisted reference matches oldFullName, replace it with newFullName.
onLocationChanged in class ItemListeneritem - an item whose absolute position is now differentoldFullName - the former Item.getFullName()newFullName - the current Item.getFullName()Items.computeRelativeNamesAfterRenaming(java.lang.String, java.lang.String, java.lang.String, hudson.model.ItemGroup)public void onDeleted(Item item)
ItemListeneronDeleted in class ItemListenerCopyright © 2019. All rights reserved.