Package org.gradle.api

# Interface IsolatedAction<T>

Type Parameters:
  `T` - The type of object the action operates on.

All Superinterfaces:
  `Serializable`

@HasImplicitReceiver @Incubating public interface IsolatedAction<T> extends Serializable
Defines an action that is applied to objects of type `IsolatedAction`, with each target getting its own isolated action instance. Each isolated action is re-created through Configuration Cache serialization before it is applied to a target. This approach ensures that sharing mutable state across targets via any means (including `BuildService`, which are not supported) is prevented. The absence of shared mutable state allows these actions to be safely executed in parallel as needed.

IMPORTANT: As isolated action instances are recreated using Configuration Cache serialization, they must adhere to the same requirements as any other object serialized into the Configuration Cache.

Since:
  8.8

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `execute(T target)`
  Performs this action against the given object.

- ## Method Details

  - ### execute

    void execute(T target)
    Performs this action against the given object.
    Parameters:
      `target` - The object to perform the action on.
    Since:
      8.8