Module org.junit.platform.engine
Class NestedClassSelector.IdentifierParser
java.lang.Object
org.junit.platform.engine.discovery.NestedClassSelector.IdentifierParser
- All Implemented Interfaces:
DiscoverySelectorIdentifierParser
- Enclosing class:
NestedClassSelector
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.junit.platform.engine.discovery.DiscoverySelectorIdentifierParser
DiscoverySelectorIdentifierParser.Context
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGet the prefix that this parser supports.parse
(DiscoverySelectorIdentifier identifier, DiscoverySelectorIdentifierParser.Context context) Parse the suppliedDiscoverySelectorIdentifier
.
-
Constructor Details
-
IdentifierParser
public IdentifierParser()
-
-
Method Details
-
getPrefix
Description copied from interface:DiscoverySelectorIdentifierParser
Get the prefix that this parser supports.- Specified by:
getPrefix
in interfaceDiscoverySelectorIdentifierParser
- Returns:
- the prefix that this parser supports; never
null
or blank
-
parse
public Optional<NestedClassSelector> parse(DiscoverySelectorIdentifier identifier, DiscoverySelectorIdentifierParser.Context context) Description copied from interface:DiscoverySelectorIdentifierParser
Parse the suppliedDiscoverySelectorIdentifier
.The JUnit Platform will only invoke this method if the supplied
DiscoverySelectorIdentifier
has a prefix that matches the value returned byDiscoverySelectorIdentifierParser.getPrefix()
.- Specified by:
parse
in interfaceDiscoverySelectorIdentifierParser
- Parameters:
identifier
- theDiscoverySelectorIdentifier
to parsecontext
- theDiscoverySelectorIdentifierParser.Context
to use for parsing- Returns:
- an
Optional
containing the parsedDiscoverySelector
; nevernull
but potentially empty
-