@Extension public static final class ItemGroupModifier.StandardModifier extends Object implements ItemGroupModifier<DirectlyModifiableTopLevelItemGroup,TopLevelItem>
ItemGroupModifier.Factory, ItemGroupModifier.StandardModifier
ExtensionPoint.LegacyInstancesAreScopedToHudson
Constructor and Description |
---|
StandardModifier() |
Modifier and Type | Method and Description |
---|---|
<II extends TopLevelItem> |
add(DirectlyModifiableTopLevelItemGroup target,
II item)
Adds an item to the target.
|
<II extends TopLevelItem> |
canAdd(DirectlyModifiableTopLevelItemGroup target,
II item)
Returns
true if the target can take the item. |
Class<DirectlyModifiableTopLevelItemGroup> |
getTargetClass()
The type of group that this modifier works on.
|
void |
remove(DirectlyModifiableTopLevelItemGroup target,
TopLevelItem item)
Removes an item from the target.
|
public Class<DirectlyModifiableTopLevelItemGroup> getTargetClass()
ItemGroupModifier
getTargetClass
in interface ItemGroupModifier<DirectlyModifiableTopLevelItemGroup,TopLevelItem>
public <II extends TopLevelItem> boolean canAdd(DirectlyModifiableTopLevelItemGroup target, II item)
ItemGroupModifier
true
if the target can take the item.canAdd
in interface ItemGroupModifier<DirectlyModifiableTopLevelItemGroup,TopLevelItem>
II
- the type of the item.target
- the target.item
- the item.true
if the target can take the item.public <II extends TopLevelItem> II add(DirectlyModifiableTopLevelItemGroup target, II item) throws IOException
ItemGroupModifier
add
in interface ItemGroupModifier<DirectlyModifiableTopLevelItemGroup,TopLevelItem>
II
- the type of the item.target
- the target.item
- the itemIOException
- if the addition could not be completed.public void remove(DirectlyModifiableTopLevelItemGroup target, TopLevelItem item) throws IOException
ItemGroupModifier
remove
in interface ItemGroupModifier<DirectlyModifiableTopLevelItemGroup,TopLevelItem>
target
- the target.item
- the itemIOException
- if the removal could not be completed.Copyright © 2016–2020. All rights reserved.