public class EventState extends Object
Contrary to the other event generators, the MicroUI States generator must be initialized with the default state of
each state. MicroUI implementation calls the method getInitialStateValue(int, int)
on startup (after front
panel device startup). The front panel project has the responsability to call the method
setInitialStateValue(int, int, int)
before device starting in order to fill the states.
Modifier and Type | Field and Description |
---|---|
static String |
COMMON_MICROUI_GENERATOR_TAG
Usual MicroUI States generator tag used in platform configuration project (
microui.xml ). |
Modifier and Type | Method and Description |
---|---|
static int |
getInitialStateValue(int eventGeneratorID,
int stateID)
Gets the state initial value (startup value).
|
static void |
sendStateEvent(int stateID,
int stateValue)
Send a STATE event to the event generator with the MicroUI generator tag
COMMON_MICROUI_GENERATOR_TAG . |
static void |
sendStateEvent(String statesEventGenerator,
int stateID,
int stateValue)
Send a STATE event to the event generator.
|
static void |
setInitialStateValue(int eventGeneratorID,
int stateID,
int value)
Initializes a state generator with its default state on startup.
|
public static final String COMMON_MICROUI_GENERATOR_TAG
microui.xml
).public static int getInitialStateValue(int eventGeneratorID, int stateID)
eventGeneratorID
- the MicroUI States
event generator.stateID
- the state machine identifier, between 0 and 255.public static void sendStateEvent(int stateID, int stateValue)
COMMON_MICROUI_GENERATOR_TAG
.stateID
- the state machine identifier, between 0 and 255.stateValue
- the new state value, between 0 and 255.sendStateEvent(String, int, int)
public static void sendStateEvent(String statesEventGenerator, int stateID, int stateValue)
The result of this method is unknown when the given event generator is not a MicroUI States
event
generator.
statesEventGenerator
- the MicroUI States
event generator.stateID
- the state machine identifier, between 0 and 255.stateValue
- the new state value, between 0 and 255.public static void setInitialStateValue(int eventGeneratorID, int stateID, int value)
eventGeneratorID
- the MicroUI States
event generator.stateID
- the state machine identifier, between 0 and 255.value
- the state value, between 0 and 255.