public class TextReaders extends Object
TextReader
s.Modifier and Type | Method and Description |
---|---|
boolean |
containsText(Container container,
String text)
Indicates whether the given
Container or any of its subcomponents contains the given text. |
static TextReaders |
instance() |
void |
register(TextReader<?> reader)
Adds the given
TextReader to this registry. |
public void register(@Nonnull TextReader<?> reader)
TextReader
to this registry.reader
- the TextReader
to add.NullPointerException
- if the given TextReader
is null
.NullPointerException
- if the supported Component
type in the given TextReader
is
null
.@RunsInEDT public boolean containsText(@Nonnull Container container, @Nonnull String text)
Container
or any of its subcomponents contains the given text.container
- the given Container
. This method is executed in the event dispatch thread (EDT).text
- the text to look for.true
if the given Container
or any of its subcomponents contains the given text;
false
otherwise.NullPointerException
- if the given Container
is null
.NullPointerException
- if the given text is null
.@Nonnull public static TextReaders instance()
Copyright © 2014–2019 AssertJ. All rights reserved.