Package wt.container.batch
Interface BatchContainer
- All Known Subinterfaces:
AttributedRoleBatchContainer,RoleBatchContainer
- All Known Implementing Classes:
AttributedRoleBatchContainerImpl,wt.container.batch.impl.BatchContainerImpl,wt.container.batch.impl.RoleBatchContainerImpl
public interface BatchContainer
The BatchContainer is a container of assertions used to collect add,
remove, and replace actions for deferred action.
Supported API: true
Extendable: false
Supported API: true
Extendable: false
-
Method Summary
Modifier and TypeMethodDescriptionbooleanAdds the specified object to the batch container.booleanDetermine if the object is in the container.elements()Return an Enumeration over the Objects in this BatchContainer.booleanOperation to allow the pre-population of container elements.booleanpopulate(Enumeration a_Elements) Operation to allow the pre-population of container elements.booleanRemoves the specified object from this BatchContainer.booleanUsed to indicate that an object has changed.intsize()The number of objects in the container, not including removed objects.
-
Method Details
-
add
Adds the specified object to the batch container. Returns false if the BatchContainer did not change based on the add, i.e. the object was already in the container. If the object is not already in the container then an AddAssertion is also added to the associated TransactionContainer.
Supported API: true- Parameters:
element-- Returns:
- boolean
-
remove
Removes the specified object from this BatchContainer. Returns false if the BatchContainer is not changed by this operation, ie.e the object is not in the batch container. Regardless of whether the object is already in this BatchContainer a RemoveAssertion is created and added to the associated TransactionContainer.
Supported API: true- Parameters:
element-- Returns:
- boolean
-
replace
Used to indicate that an object has changed. Returns true if the specified object is in the container. Regardless of whether the specified object is in the container, a ReplaceAsssertion will be created and added to the associated TransactionContainer.
Supported API: true- Parameters:
element-- Returns:
- boolean
-
elements
Enumeration elements()Return an Enumeration over the Objects in this BatchContainer. Objects for which the most recent Assertion is a RemoveAssertion will not be included in the Enumeration
Supported API: true- Returns:
- Enumeration
-
contains
Determine if the object is in the container. Objects for which a remove assertion has been applied will not be returned.
Supported API: true- Parameters:
element-- Returns:
- boolean
-
size
int size()The number of objects in the container, not including removed objects.
Supported API: true- Returns:
- int
-
populate
Operation to allow the pre-population of container elements. This allows objects to be added to the container without creating a corresponding Assertion. Returns true if the BatchContainer changed due to this operation.
Supported API: true- Parameters:
a_Element-- Returns:
- boolean
-
populate
Operation to allow the pre-population of container elements. The container must be empty when populdate is called. Returns true if the BatchContainer changed due to this operation.
Supported API: true- Parameters:
a_Elements-- Returns:
- boolean
-