Interface DefaultSyntaxInfos.Structure<E extends Structure>
- Type Parameters:
E
- The class providing the implementation of the Structure this info represents.
- All Superinterfaces:
Builder.Buildable<SyntaxInfo.Builder<?,
,?>, SyntaxInfo<?>> DefaultSyntaxInfos
,SyntaxInfo<E>
- Enclosing interface:
DefaultSyntaxInfos
@Experimental
public static interface DefaultSyntaxInfos.Structure<E extends Structure>
extends SyntaxInfo<E>
A syntax info to be used for
Structure
s.
It contains additional details including the EntryValidator
to use, if any.-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
DefaultSyntaxInfos.Structure.Builder<B extends DefaultSyntaxInfos.Structure.Builder<B,
E>, E extends Structure> A Structure-specific builder is used for constructing a new Structure syntax info.static enum
Represents type ofNode
s that can represent a Structure.Nested classes/interfaces inherited from interface org.skriptlang.skript.registration.DefaultSyntaxInfos
DefaultSyntaxInfos.Expression<E extends Expression<R>,
R>, DefaultSyntaxInfos.Structure<E extends Structure> -
Field Summary
Fields inherited from interface org.skriptlang.skript.registration.SyntaxInfo
COMBINED, PATTERN_MATCHES_EVERYTHING, SIMPLE
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()
static <E extends Structure>
DefaultSyntaxInfos.Structure.Builder<? extends DefaultSyntaxInfos.Structure.Builder<?, E>, E> Constructs a builder for a structure syntax info.@Nullable EntryValidator
nodeType()
-
Method Details
-
builder
@Contract("_ -> new") static <E extends Structure> DefaultSyntaxInfos.Structure.Builder<? extends DefaultSyntaxInfos.Structure.Builder<?,E>, builderE> (Class<E> structureClass) Constructs a builder for a structure syntax info.- Type Parameters:
E
- The class providing the implementation of the Structure this info represents.- Parameters:
structureClass
- The Structure class the info will represent.- Returns:
- A Structure-specific builder for creating a syntax info representing
structureClass
. By default, thenodeType()
of the builder isDefaultSyntaxInfos.Structure.NodeType.SECTION
.
-
builder
@Contract("-> new") DefaultSyntaxInfos.Structure.Builder<? extends DefaultSyntaxInfos.Structure.Builder<?,E>, builder()E> - Specified by:
builder
in interfaceBuilder.Buildable<SyntaxInfo.Builder<?,
?>, SyntaxInfo<?>> - Specified by:
builder
in interfaceSyntaxInfo<E extends Structure>
- Returns:
- A builder representing this object.
-
entryValidator
- Returns:
- The entry validator to use for handling the Structure's entries. If null, the Structure is expected to manually handle any entries.
-
nodeType
DefaultSyntaxInfos.Structure.NodeType nodeType()- Returns:
- The type of
Node
s that can represent the Structure.
-