case class StructuredPrefixParser(needsMention: (CacheSnapshot, Message) => Future[Boolean], symbols: (CacheSnapshot, Message) => Future[Seq[String]], aliases: (CacheSnapshot, Message) => Future[Seq[String]], caseSensitive: (CacheSnapshot, Message) => Future[Boolean] = (_, _) => Future.successful(false), canExecute: (CacheSnapshot, Message) => Future[Boolean] = (_, _) => Future.successful(true), mentionOrPrefix: (CacheSnapshot, Message) => Future[Boolean] = (_, _) => Future.successful(true)) extends PrefixParser with Product with Serializable
Represents information about how a command can be invoked in a structural way.
- needsMention
If the command needs a mention
- symbols
The valid prefix symbols for the command
- aliases
The aliases for the command
- caseSensitive
If the aliases should be case sensitive
- canExecute
A early precheck if the command can execute at all
- mentionOrPrefix
If true allows one to use a mention in place of a prefix. If needsMention is also true, skips the symbol check.
- Source
- prefixParser.scala
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- StructuredPrefixParser
- Serializable
- Product
- Equals
- PrefixParser
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Instance Constructors
- new StructuredPrefixParser(needsMention: (CacheSnapshot, Message) => Future[Boolean], symbols: (CacheSnapshot, Message) => Future[Seq[String]], aliases: (CacheSnapshot, Message) => Future[Seq[String]], caseSensitive: (CacheSnapshot, Message) => Future[Boolean] = (_, _) => Future.successful(false), canExecute: (CacheSnapshot, Message) => Future[Boolean] = (_, _) => Future.successful(true), mentionOrPrefix: (CacheSnapshot, Message) => Future[Boolean] = (_, _) => Future.successful(true))
- needsMention
If the command needs a mention
- symbols
The valid prefix symbols for the command
- aliases
The aliases for the command
- caseSensitive
If the aliases should be case sensitive
- canExecute
A early precheck if the command can execute at all
- mentionOrPrefix
If true allows one to use a mention in place of a prefix. If needsMention is also true, skips the symbol check.
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- val aliases: (CacheSnapshot, Message) => Future[Seq[String]]
- def apply(message: Message)(implicit c: CacheSnapshot, ec: ExecutionContext): Future[MessageParser[Unit]]
- Definition Classes
- StructuredPrefixParser → PrefixParser
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- val canExecute: (CacheSnapshot, Message) => Future[Boolean]
- val caseSensitive: (CacheSnapshot, Message) => Future[Boolean]
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val mentionOrPrefix: (CacheSnapshot, Message) => Future[Boolean]
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- val needsMention: (CacheSnapshot, Message) => Future[Boolean]
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- val symbols: (CacheSnapshot, Message) => Future[Seq[String]]
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])