Interface TransformAction
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Represents an action to be performed that transforms a node in the
 configuration tree.
- Since:
- 4.0.0
- 
Method SummaryModifier and TypeMethodDescriptionstatic TransformActionremove()Create a transform action that will remove the node at a specified path.static TransformActionRename a nodestatic <V> TransformActionset(io.leangen.geantyref.TypeToken<V> type, @Nullable V value) Create a transform action that will change the value of a node to one of the specified type.static <V> TransformActionCreate a transform action that will change the value of a node to one of the specified type.static <V> TransformActionCreate a transform action that will change the value of a node to one of the specified type.Object @Nullable []visitPath(NodePath path, ConfigurationNode value) Called at a certain path, with the node at that path.
- 
Method Details- 
removeCreate a transform action that will remove the node at a specified path.- Returns:
- new action
- Since:
- 4.0.0
 
- 
renameRename a nodeThis transformation cannot be applied to the root node. - Parameters:
- newKey- the new key
- Returns:
- new action
- Since:
- 4.0.0
 
- 
setCreate a transform action that will change the value of a node to one of the specified type.- Type Parameters:
- V- value type
- Parameters:
- type- value type
- value- value
- Returns:
- new transformation action
- Since:
- 4.0.0
 
- 
setstatic <V> TransformAction set(io.leangen.geantyref.TypeToken<V> type, Supplier<@Nullable V> valueSupplier) Create a transform action that will change the value of a node to one of the specified type.- Type Parameters:
- V- value type
- Parameters:
- type- value type
- valueSupplier- supplier returning a value on each call
- Returns:
- new transformation action
- Since:
- 4.0.0
 
- 
setCreate a transform action that will change the value of a node to one of the specified type.- Type Parameters:
- V- value type
- Parameters:
- type- value type
- valueSupplier- supplier returning a value on each call
- Returns:
- new transformation action
- Since:
- 4.0.0
 
- 
visitPathCalled at a certain path, with the node at that path.Caution: The state of the pathis only guaranteed to be accurate during a run of the transform function. UseNodePath.copy()if the path's state needs to be stored.- Parameters:
- path- the path of the given node
- value- the node at the input path. May be modified
- Returns:
- a modified path, or null if the path is to stay the same
- Throws:
- ConfigurateException
- Since:
- 4.0.0
 
 
-