-
- Type Parameters:
C
- type of the children. Should typically be the sub-type implementing this interface itself.
- All Superinterfaces:
Iterable<C>
- All Known Subinterfaces:
ValidationResult
,Validator<V>
- All Known Implementing Classes:
AbstractComposedValidator
,AbstractValidationResult
,AbstractValidator
,AbstractValidatorRange
,AbstractValueValidator
,ComposedValidationFailure
,ComposedValidator
,ProjectionValidator
,ValidationFailure
,ValidationResultValid
,ValidatorCharSequnceSize
,ValidatorCollectionElements
,ValidatorCollectionSize
,ValidatorCompare
,ValidatorEmail
,ValidatorEmailSpec
,ValidatorHost
,ValidatorHostName
,ValidatorInstantAfter
,ValidatorInstantBefore
,ValidatorInstantFuture
,ValidatorInstantPast
,ValidatorIpAddress
,ValidatorIpV4Address
,ValidatorIpV6Address
,ValidatorLocalDateAfter
,ValidatorLocalDateBefore
,ValidatorLocalDateFuture
,ValidatorLocalDatePast
,ValidatorLocalDateTimeAfter
,ValidatorLocalDateTimeBefore
,ValidatorLocalDateTimeFuture
,ValidatorLocalDateTimePast
,ValidatorLocalTimeAfter
,ValidatorLocalTimeBefore
,ValidatorLocalTimeFuture
,ValidatorLocalTimePast
,ValidatorMandatory
,ValidatorMapKeys
,ValidatorMapSize
,ValidatorMapValues
,ValidatorOffsetDateTimeAfter
,ValidatorOffsetDateTimeBefore
,ValidatorOffsetDateTimeFuture
,ValidatorOffsetDateTimePast
,ValidatorOffsetTimeAfter
,ValidatorOffsetTimeBefore
,ValidatorOffsetTimeFuture
,ValidatorOffsetTimePast
,ValidatorPasswordConfirmation
,ValidatorPattern
,ValidatorPhoneNumber
,ValidatorRange
,ValidatorTemporalAfter
,ValidatorTemporalBefore
,ValidatorTemporalFuture
,ValidatorTemporalPast
,ValidatorZonedDateTimeAfter
,ValidatorZonedDateTimeBefore
,ValidatorZonedDateTimeFuture
,ValidatorZonedDateTimePast
public interface Composable<C> extends Iterable<C>
Interface for an object that may containchildren
.- Since:
- 1.0.0
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default C
getChild(int index)
Gets the child-object at the givenindex
.default int
getChildCount()
default Iterator<C>
iterator()
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
getChildCount
default int getChildCount()
- Returns:
- the number of contained
children
. - See Also:
getChild(int)
,Collection.size()
-
getChild
default C getChild(int index)
Gets the child-object at the givenindex
.- Parameters:
index
- is the index of the child to get.- Returns:
- the requested child.
- Throws:
IndexOutOfBoundsException
- if the givenindex
is not in the range from0
to
.child-count
- 1- See Also:
List.get(int)
-
-