-
- Type Parameters:
T- the type of model object
- All Superinterfaces:
- Collection<T>, Iterable<T>, ManagedSet<T>, Set<T>
@Incubating public interface ModelSet<T> extends ManagedSet<T>
A set of managed model objects.
Managedtypes may declare managed set properties. Managed sets can only contain managed types.Managed set objects cannot be mutated via the mutative methods of the
Setinterface (e.g.Set.add(Object),Set.clear()). To add elements to the set, thecreate(Action)method can be used.
-
-
Method Summary
Methods Modifier and Type Method and Description voidafterEach(Action<? super T> configAction)Apply the given action to each set element just before it is considered to be realised.
voidbeforeEach(Action<? super T> configAction)Apply the given action to each set element just after it is created.
voidcreate(Action<? super T> action)Declares a new set element, configured by the given action.
-
-
-
Method Detail
-
create
void create(Action<? super T> action)
Declares a new set element, configured by the given action.
- Specified by:
createin interfaceManagedSet<T>- Parameters:
action- the object configuration
-
beforeEach
void beforeEach(Action<? super T> configAction)
Apply the given action to each set element just after it is created.
The configuration action is equivalent in terms of lifecycle to
Defaultsrule methods.- Specified by:
beforeEachin interfaceManagedSet<T>- Parameters:
configAction- the object configuration
-
afterEach
void afterEach(Action<? super T> configAction)
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
Finalizerule methods.- Specified by:
afterEachin interfaceManagedSet<T>- Parameters:
configAction- the object configuration
-
-