Class ActionConfig
- java.lang.Object
-
- com.inductiveautomation.perspective.common.config.ActionConfig
-
public class ActionConfig extends java.lang.Object
ActionConfig holds the configuration of a single action. These are held as part of the collection of actions that may respond to an event. SeeEventConfig
Note that we also define all of the IDs of inductive automation's built-in action types here on this class, because it is a convenient place in common scope to define them.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ActionConfig.ActionScope
static class
ActionConfig.RuntimeGsonAdapter
static class
ActionConfig.StandardGsonAdapter
Special gson adapter to avoid extra fields when enabled is true or when the permissions are at their defaults.
-
Field Summary
Fields Modifier and Type Field Description com.inductiveautomation.ignition.common.gson.JsonObject
config
java.lang.Boolean
enabled
If null, action is enabled.PermissionsConfig
permissions
ActionConfig.ActionScope
scope
static java.lang.String
SCRIPT_ACTION_ID
java.lang.String
type
-
Constructor Summary
Constructors Constructor Description ActionConfig(ActionConfig.ActionScope scope, java.lang.String type, boolean enabled, com.inductiveautomation.ignition.common.gson.JsonObject config, PermissionsConfig permissions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
PermissionsConfig
getPermissions()
int
hashCode()
boolean
isEnabled()
java.lang.String
toString()
-
-
-
Field Detail
-
SCRIPT_ACTION_ID
public static final java.lang.String SCRIPT_ACTION_ID
- See Also:
- Constant Field Values
-
scope
public final ActionConfig.ActionScope scope
-
type
public final java.lang.String type
-
config
public final com.inductiveautomation.ignition.common.gson.JsonObject config
-
enabled
@Nullable public final java.lang.Boolean enabled
If null, action is enabled.
-
permissions
@Nullable public final PermissionsConfig permissions
-
-
Constructor Detail
-
ActionConfig
public ActionConfig(ActionConfig.ActionScope scope, java.lang.String type, boolean enabled, com.inductiveautomation.ignition.common.gson.JsonObject config, PermissionsConfig permissions)
-
-
Method Detail
-
isEnabled
public boolean isEnabled()
-
getPermissions
@Nonnull public PermissionsConfig getPermissions()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-