Interface EntityDataInfo.Builder<B extends EntityDataInfo.Builder<B,Data,E>, Data extends EntityData<E>, E extends org.bukkit.entity.Entity>
- Type Parameters:
B- The type of builder being used.Data- TheEntityDataclass being used.E- TheEntityclassDatais assigned to.
- All Superinterfaces:
SyntaxInfo.Builder<B,Data>
- Enclosing interface:
EntityDataInfo<Data extends EntityData<E>, E extends org.bukkit.entity.Entity>
public static interface EntityDataInfo.Builder<B extends EntityDataInfo.Builder<B,Data,E>, Data extends EntityData<E>, E extends org.bukkit.entity.Entity>
extends SyntaxInfo.Builder<B,Data>
Builder used for constructing a new
EntityDataInfo.-
Method Summary
Modifier and TypeMethodDescriptiondefault BaddPattern(String pattern) Adds a new pattern to the syntax info.default BaddPatterns(String... patterns) Adds new patterns to the syntax info.default BaddPatterns(Collection<String> patterns) Adds new patterns to the syntax info.build()Builds a new syntax info from the set details.default BRemoves all patterns from the syntax info.dataPatterns(EntityData.EntityDataPatterns<?> dataPatterns) Sets the data patterns containing the patterns to be used.defaultGroupIndex(int index) Sets the default group index.entityClass(Class<? extends E> entityClass) Sets the entity class the info correlates to.entityType(@Nullable org.bukkit.entity.EntityType entityType) Sets the entity type the info correlates to.Methods inherited from interface SyntaxInfo.Builder
applyTo, origin, priority, supplier
-
Method Details
-
dataPatterns
Sets the data patterns containing the patterns to be used.- Parameters:
dataPatterns- The patterns to use.- Returns:
- This builder.
-
defaultGroupIndex
Sets the default group index. Correlates to theEntityData.PatternGroupcontained inEntityData.EntityDataPatterns.- Parameters:
index- The index of the group to default to.- Returns:
- This builder.
-
entityType
Sets the entity type the info correlates to.- Parameters:
entityType- The entity type.- Returns:
- This builder.
-
entityClass
-
build
EntityDataInfo<Data,E> build()Description copied from interface:SyntaxInfo.BuilderBuilds a new syntax info from the set details.- Specified by:
buildin interfaceSyntaxInfo.Builder<B extends EntityDataInfo.Builder<B,Data, E>, Data extends EntityData<E>> - Returns:
- A syntax info representing the class providing the syntax's implementation.
-
addPattern
Description copied from interface:SyntaxInfo.BuilderAdds a new pattern to the syntax info.- Specified by:
addPatternin interfaceSyntaxInfo.Builder<B extends EntityDataInfo.Builder<B,Data, E>, Data extends EntityData<E>> - Parameters:
pattern- The pattern to add.- Returns:
- This builder.
- See Also:
-
addPatterns
Description copied from interface:SyntaxInfo.BuilderAdds new patterns to the syntax info.- Specified by:
addPatternsin interfaceSyntaxInfo.Builder<B extends EntityDataInfo.Builder<B,Data, E>, Data extends EntityData<E>> - Parameters:
patterns- The patterns to add.- Returns:
- This builder.
- See Also:
-
addPatterns
Description copied from interface:SyntaxInfo.BuilderAdds new patterns to the syntax info.- Specified by:
addPatternsin interfaceSyntaxInfo.Builder<B extends EntityDataInfo.Builder<B,Data, E>, Data extends EntityData<E>> - Parameters:
patterns- The patterns to add.- Returns:
- This builder.
- See Also:
-
clearPatterns
Description copied from interface:SyntaxInfo.BuilderRemoves all patterns from the syntax info.- Specified by:
clearPatternsin interfaceSyntaxInfo.Builder<B extends EntityDataInfo.Builder<B,Data, E>, Data extends EntityData<E>> - Returns:
- This builder.
- See Also:
-