CommandTrigger class

A trigger which can fire a Command.

Annotations
  • @JsonSerializable()

Constructors

CommandTrigger({required String name, required String description, CommandKeyboardKey? keyboardKey, GameControllerButton? button})
Create an instance.
const
CommandTrigger.basic({required String name, required String description, ScanCode? scanCode, GameControllerButton? button})
Create a basic trigger.
factory
CommandTrigger.fromJson(Map<String, dynamic> json)
Create an instance from a JSON object.
factory

Properties

button → GameControllerButton?
The games controller button which must be pressed to trigger this command.
final
description String
The description of this command.
final
hashCode int
The hash code for this object.
no setterinherited
keyboardKey CommandKeyboardKey?
The keyboard key which must be held down in order for this command to be triggered.
final
name String
The name of the command which this trigger will send.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Convert an instance to JSON.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited