ModelSet (Gradle API 9.7.1)
Description: declaration: package: org.gradle.model, interface: ModelSet

# Interface ModelSet<T>

Type Parameters:
  `T` - the type of model object

All Superinterfaces:
  `Collection<T>, Iterable<T>, ModelElement, Named, Set<T>`

@Incubating @Deprecated public interface ModelSet<T> extends Set<T>, ModelElement
Deprecated.
The Gradle software model is deprecated and will be removed in Gradle 10. Use the new component model (e.g. `cpp-application`, `cpp-library`, `swift-application`, `swift-library`, `xctest`) instead.
A set of managed model objects.

`Managed` types may declare managed set properties. Managed sets can only contain managed types.

Managed set objects cannot be mutated via the mutative methods of the `Set` interface (e.g. `Set.add(Object)`, `Set.clear()`). To add elements to the set, the `create(Action)` method can be used.

- ## Nested Class Summary

  ### Nested classes/interfaces inherited from interface Named

  `Named.Namer`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `afterEach(Action<? super T> configAction)`
  Deprecated.
  Apply the given action to each set element just before it is considered to be realised.
  `void`
  `beforeEach(Action<? super T> configAction)`
  Deprecated.
  Apply the given action to each set element just after it is created.
  `void`
  `create(Action<? super T> action)`
  Deprecated.
  Declares a new set element, configured by the given action.

  ### Methods inherited from interface Collection

  `parallelStream, removeIf, stream, toArray`

  ### Methods inherited from interface Iterable

  `forEach`

  ### Methods inherited from interface ModelElement

  `getDisplayName, getName`

  ### Methods inherited from interface Set

  `add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, spliterator, toArray, toArray`

- ## Method Details

  - ### create

    void create(Action<? super T> action)
    Deprecated.
    Declares a new set element, configured by the given action.
    Parameters:
      `action` - the object configuration

  - ### beforeEach

    void beforeEach(Action<? super T> configAction)
    Deprecated.
    Apply the given action to each set element just after it is created.

    The configuration action is equivalent in terms of lifecycle to `Defaults` rule methods.

    Parameters:
      `configAction` - the object configuration

  - ### afterEach

    void afterEach(Action<? super T> configAction)
    Deprecated.
    Apply the given action to each set element just before it is considered to be realised.

    The configuration action is equivalent in terms of lifecycle to `Finalize` rule methods.

    Parameters:
      `configAction` - the object configuration