|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjmri.implementation.DefaultConditionalAction
public class DefaultConditionalAction
ConditionalAction.java The consequent of the antecedent of the conditional proposition. The data for the action to be taken when a Conditional calculates to True
This is in the implementations package because of a Swing dependence via the times. Java 1.5 or Java 1.6 might make it possible to break that, which will simplify things.
| Field Summary | |
|---|---|
protected NamedBeanHandleManager |
nbhm
|
| Constructor Summary | |
|---|---|
DefaultConditionalAction()
|
|
DefaultConditionalAction(int option,
int type,
String name,
int actionData,
String actionStr)
|
|
| Method Summary | |
|---|---|
String |
description(boolean triggerType)
|
int |
getActionData()
Integer data for action |
String |
getActionDataString()
|
static String |
getActionDataString(int t,
int data)
|
String |
getActionString()
String data for action |
static String |
getActionTypeString(int t)
Convert Consequent Type to Text String |
NamedBean |
getBean()
|
String |
getDeviceName()
Name of the device or element that is effected |
static String |
getItemTypeString(int t)
Convert Variable Type to Text String |
ActionListener |
getListener()
|
NamedBeanHandle<?> |
getNamedBean()
|
int |
getOption()
Options on when action is taken |
String |
getOptionString(boolean type)
return String name of the option for this consequent type |
static String |
getOptionString(int opt,
boolean type)
Convert consequent option to String |
Sound |
getSound()
get Sound file |
Timer |
getTimer()
|
int |
getType()
The consequent device or element type |
String |
getTypeString()
return String name of this consequent type |
boolean |
isTimerActive()
|
void |
setActionData(int actionData)
|
void |
setActionData(String actionData)
Sets action data from user's name for it |
void |
setActionString(String actionString)
|
void |
setDeviceName(String deviceName)
|
void |
setListener(ActionListener listener)
|
void |
setOption(int option)
|
protected void |
setSound(Sound sound)
set Sound file |
void |
setTimer(Timer timer)
|
void |
setType(int type)
|
void |
setType(String type)
Sets type from user's name for it |
void |
startTimer()
|
void |
stopTimer()
|
static int |
stringToActionData(String str)
Identifies action Data from Text String Note: if string does not correspond to an action Data as defined in ConditionalAction, returns -1. |
static int |
stringToActionType(String str)
Identifies action Type from Text String Note: if string does not correspond to an action type as defined in ConditionalAction, returns 0. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected NamedBeanHandleManager nbhm
| Constructor Detail |
|---|
public DefaultConditionalAction()
public DefaultConditionalAction(int option,
int type,
String name,
int actionData,
String actionStr)
| Method Detail |
|---|
public int getType()
getType in interface ConditionalActionpublic void setType(int type)
setType in interface ConditionalActionpublic void setType(String type)
setType in interface ConditionalActionpublic String getDeviceName()
getDeviceName in interface ConditionalActionpublic void setDeviceName(String deviceName)
setDeviceName in interface ConditionalActionpublic NamedBeanHandle<?> getNamedBean()
getNamedBean in interface ConditionalActionpublic NamedBean getBean()
public int getOption()
getOption in interface ConditionalActionpublic void setOption(int option)
setOption in interface ConditionalActionpublic int getActionData()
getActionData in interface ConditionalActionpublic void setActionData(int actionData)
setActionData in interface ConditionalActionpublic void setActionData(String actionData)
setActionData in interface ConditionalActionpublic String getActionString()
getActionString in interface ConditionalActionpublic void setActionString(String actionString)
setActionString in interface ConditionalActionpublic Timer getTimer()
getTimer in interface ConditionalActionpublic void setTimer(Timer timer)
setTimer in interface ConditionalActionpublic boolean isTimerActive()
isTimerActive in interface ConditionalActionpublic void startTimer()
startTimer in interface ConditionalActionpublic void stopTimer()
stopTimer in interface ConditionalActionpublic ActionListener getListener()
getListener in interface ConditionalActionpublic void setListener(ActionListener listener)
setListener in interface ConditionalActionpublic Sound getSound()
getSound in interface ConditionalActionprotected void setSound(Sound sound)
public String getTypeString()
getTypeString in interface ConditionalActionpublic String getOptionString(boolean type)
getOptionString in interface ConditionalActionpublic String getActionDataString()
getActionDataString in interface ConditionalActionpublic static String getItemTypeString(int t)
public static String getActionTypeString(int t)
public static String getOptionString(int opt,
boolean type)
public static int stringToActionType(String str)
public static int stringToActionData(String str)
public static String getActionDataString(int t,
int data)
public String description(boolean triggerType)
description in interface ConditionalAction
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||