Interface NodeBuilder<N extends ScopedNode<N,B>,B extends NodeBuilder<N,B>>
- Type Parameters:
N- the node typeB- the node builder type
- All Known Subinterfaces:
ChatMetaNode.Builder<N,,B> DisplayNameNode.Builder,InheritanceNode.Builder,MetaNode.Builder,PermissionNode.Builder,PrefixNode.Builder,RegexPermissionNode.Builder,SuffixNode.Builder,WeightNode.Builder
Builder for
Nodes.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Creates aNodeinstance from the builder.Marks that the node being built should never expire.context(@NonNull ContextSet contextSet) Sets the extra contexts for the node.expiry(long expiryEpochSeconds) Sets the time when the node should expire.Sets the time when the node should expire.expiry(@Nullable TemporalAccessor expiry) Sets the time when the node should expire.expiry(@Nullable TemporalAmount duration) Sets the time when the node should expire.negated(boolean negated) Sets the value of negated for the node.value(boolean value) Sets the value of the node.withContext(@NonNull String key, @NonNull String value) Appends an extra context onto the node.withContext(@NonNull ContextSet contextSet) Appends extra contexts onto the node.withMetadata(@NonNull NodeMetadataKey<T> key, @Nullable T metadata) Sets the given metadata for the node.
-
Method Details
-
value
-
negated
-
expiry
-
expiry
Sets the time when the node should expire.- Parameters:
expiry- the expiry time- Returns:
- the builder
- See Also:
-
expiry
Sets the time when the node should expire.The expiry time is calculated relative to the current system time.
- Parameters:
duration- how long the node should be added for- Returns:
- the builder
- Since:
- 5.1
- See Also:
-
expiry
-
clearExpiry
-
context
Sets the extra contexts for the node.- Parameters:
contextSet- a context set- Returns:
- the builder
- See Also:
-
withContext
-
withContext
Appends extra contexts onto the node.- Parameters:
contextSet- a context set- Returns:
- the builder
- See Also:
-
withMetadata
Sets the given metadata for the node.- Type Parameters:
T- the metadata type- Parameters:
key- the metadata keymetadata- the metadata- Returns:
- the builder
-
build
-