Package org.assertj.core.api
Interface ExtensionPoints<SELF extends ExtensionPoints<SELF,ACTUAL>,ACTUAL>
-
- Type Parameters:
SELF
- the "self" type of this assertion class. Please read "Emulating 'self types' using Java Generics to simplify fluent API implementation" for more details.ACTUAL
- the type of the "actual" value.
- All Known Subinterfaces:
Assert<SELF,ACTUAL>
- All Known Implementing Classes:
Abstract2DArrayAssert
,AbstractArrayAssert
,AbstractAssert
,AbstractAtomicFieldUpdaterAssert
,AbstractAtomicReferenceAssert
,AbstractBigDecimalAssert
,AbstractBigIntegerAssert
,AbstractBooleanArrayAssert
,AbstractBooleanAssert
,AbstractByteArrayAssert
,AbstractByteAssert
,AbstractCharacterAssert
,AbstractCharArrayAssert
,AbstractCharSequenceAssert
,AbstractClassAssert
,AbstractComparableAssert
,AbstractCompletableFutureAssert
,AbstractDateAssert
,AbstractDoubleArrayAssert
,AbstractDoubleAssert
,AbstractDurationAssert
,AbstractEnumerableAssert
,AbstractFileAssert
,AbstractFloatArrayAssert
,AbstractFloatAssert
,AbstractFutureAssert
,AbstractInputStreamAssert
,AbstractInstantAssert
,AbstractIntArrayAssert
,AbstractIntegerAssert
,AbstractIterableAssert
,AbstractIterableSizeAssert
,AbstractIteratorAssert
,AbstractListAssert
,AbstractLocalDateAssert
,AbstractLocalDateTimeAssert
,AbstractLocalTimeAssert
,AbstractLongAdderAssert
,AbstractLongArrayAssert
,AbstractLongAssert
,AbstractMapAssert
,AbstractMapSizeAssert
,AbstractObjectArrayAssert
,AbstractObjectAssert
,AbstractOffsetDateTimeAssert
,AbstractOffsetTimeAssert
,AbstractOptionalAssert
,AbstractOptionalDoubleAssert
,AbstractOptionalIntAssert
,AbstractOptionalLongAssert
,AbstractPathAssert
,AbstractPeriodAssert
,AbstractPredicateAssert
,AbstractPredicateLikeAssert
,AbstractShortArrayAssert
,AbstractShortAssert
,AbstractSpliteratorAssert
,AbstractStringAssert
,AbstractTemporalAssert
,AbstractThrowableAssert
,AbstractUriAssert
,AbstractUrlAssert
,AbstractZonedDateTimeAssert
,AtomicBooleanAssert
,AtomicIntegerArrayAssert
,AtomicIntegerAssert
,AtomicIntegerFieldUpdaterAssert
,AtomicLongArrayAssert
,AtomicLongAssert
,AtomicLongFieldUpdaterAssert
,AtomicMarkableReferenceAssert
,AtomicReferenceArrayAssert
,AtomicReferenceAssert
,AtomicReferenceFieldUpdaterAssert
,AtomicStampedReferenceAssert
,BigDecimalAssert
,BigIntegerAssert
,Boolean2DArrayAssert
,BooleanArrayAssert
,BooleanAssert
,Byte2DArrayAssert
,ByteArrayAssert
,ByteAssert
,Char2DArrayAssert
,CharacterAssert
,CharArrayAssert
,CharSequenceAssert
,ClassAssert
,ClassBasedNavigableIterableAssert
,ClassBasedNavigableListAssert
,CompletableFutureAssert
,DateAssert
,Double2DArrayAssert
,DoubleArrayAssert
,DoubleAssert
,DoublePredicateAssert
,DurationAssert
,FactoryBasedNavigableIterableAssert
,FactoryBasedNavigableListAssert
,FileAssert
,Float2DArrayAssert
,FloatArrayAssert
,FloatAssert
,FutureAssert
,GenericComparableAssert
,InputStreamAssert
,InstantAssert
,Int2DArrayAssert
,IntArrayAssert
,IntegerAssert
,IntPredicateAssert
,IterableAssert
,IterableSizeAssert
,IteratorAssert
,ListAssert
,LocalDateAssert
,LocalDateTimeAssert
,LocalTimeAssert
,Long2DArrayAssert
,LongAdderAssert
,LongArrayAssert
,LongAssert
,LongPredicateAssert
,MapAssert
,MapSizeAssert
,Object2DArrayAssert
,ObjectArrayAssert
,ObjectAssert
,OffsetDateTimeAssert
,OffsetTimeAssert
,OptionalAssert
,OptionalDoubleAssert
,OptionalIntAssert
,OptionalLongAssert
,PathAssert
,PeriodAssert
,PredicateAssert
,ProxyableClassAssert
,ProxyableIterableAssert
,ProxyableListAssert
,ProxyableMapAssert
,ProxyableObjectArrayAssert
,ProxyableObjectAssert
,ProxyablePredicateAssert
,RecursiveComparisonAssert
,Short2DArrayAssert
,ShortArrayAssert
,ShortAssert
,SpliteratorAssert
,StringAssert
,ThrowableAssert
,ThrowableAssertAlternative
,UriAssert
,UrlAssert
,ZonedDateTimeAssert
public interface ExtensionPoints<SELF extends ExtensionPoints<SELF,ACTUAL>,ACTUAL>
Mechanism for extending assertion classes.- Author:
- Alex Ruiz, Mikhail Mazursky
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SELF
doesNotHave(Condition<? super ACTUAL> condition)
Verifies that the actual value does not satisfy the given condition.SELF
has(Condition<? super ACTUAL> condition)
Verifies that the actual value satisfies the given condition.SELF
is(Condition<? super ACTUAL> condition)
Verifies that the actual value satisfies the given condition.SELF
isNot(Condition<? super ACTUAL> condition)
Verifies that the actual value does not satisfy the given condition.SELF
satisfies(Condition<? super ACTUAL> condition)
Verifies that the actual value satisfies the given condition.
-
-
-
Method Detail
-
is
SELF is(Condition<? super ACTUAL> condition)
Verifies that the actual value satisfies the given condition. This method is an alias for
.has(Condition)
- Parameters:
condition
- the given condition.- Returns:
this ExtensionPoints
object.- Throws:
NullPointerException
- if the given condition isnull
.AssertionError
- if the actual value does not satisfy the given condition.- See Also:
has(Condition)
-
isNot
SELF isNot(Condition<? super ACTUAL> condition)
Verifies that the actual value does not satisfy the given condition. This method is an alias for
.doesNotHave(Condition)
- Parameters:
condition
- the given condition.- Returns:
this ExtensionPoints
object.- Throws:
NullPointerException
- if the given condition isnull
.AssertionError
- if the actual value satisfies the given condition.- See Also:
isNot(Condition)
-
has
SELF has(Condition<? super ACTUAL> condition)
Verifies that the actual value satisfies the given condition. This method is an alias for
.is(Condition)
- Parameters:
condition
- the given condition.- Returns:
this ExtensionPoints
object.- Throws:
NullPointerException
- if the given condition isnull
.AssertionError
- if the actual value does not satisfy the given condition.- See Also:
is(Condition)
-
doesNotHave
SELF doesNotHave(Condition<? super ACTUAL> condition)
Verifies that the actual value does not satisfy the given condition. This method is an alias for
.isNot(Condition)
- Parameters:
condition
- the given condition.- Returns:
this ExtensionPoints
object.- Throws:
NullPointerException
- if the given condition isnull
.AssertionError
- if the actual value satisfies the given condition.- See Also:
isNot(Condition)
-
satisfies
SELF satisfies(Condition<? super ACTUAL> condition)
Verifies that the actual value satisfies the given condition. This method is an alias for
.is(Condition)
Example:
// Given Condition<String> fairyTale = new Condition<>(s -> s.startsWith("Once upon a time"), "fairy tale start"); // When String littleRedCap = "Once upon a time there was a dear little girl ..."; // Then assertThat(littleRedCap).satisfies(fairyTale);
- Parameters:
condition
- the given condition.- Returns:
this ExtensionPoints
object.- Throws:
NullPointerException
- if the given condition isnull
.AssertionError
- if the actual value does not satisfy the given condition.- Since:
- 3.11
- See Also:
is(Condition)
-
-