public class AutomaticState
extends java.lang.Object
Constructor and Description |
---|
AutomaticState()
Constructor without parameters
|
AutomaticState(int numRules)
Constructor with defined number of rules
|
AutomaticState(java.lang.String name,
int numRules)
Constructor with name and defined number of rules
|
Modifier and Type | Method and Description |
---|---|
void |
addListRules(AutomaticRule rule)
updateListRules: add a rule to the list of rules
|
java.util.ArrayList<AutomaticRule> |
getListRules()
getListRules: return the list of rules on the state
|
java.lang.String |
getName()
getName: returns the name of the rule
|
int |
getNumRules()
getNumRules: return the number of rules on the state
|
AutomaticRule |
getRule(int pos)
getRule: return the rule on the specified position
|
AutomaticRule |
getRule(java.lang.String name)
getRule: return the rule with the specified name
|
void |
setListRules(java.util.ArrayList<AutomaticRule> listRules)
setListRules: set the list of rules
|
void |
setName(java.lang.String name)
setName: set the name of the rule
|
void |
setNumRules(int numRules)
setNumRules: set the number of rules on the state
|
java.lang.String |
toString()
toString: return the string with the current state
|
void |
updateListRules(AutomaticRule rule,
int pos)
updateListRules: update the rule in the position specified
|
public AutomaticState()
public AutomaticState(int numRules)
numRules
- number of rules of this statepublic AutomaticState(java.lang.String name, int numRules)
name
- name of the statenumRules
- number of rules of this statepublic java.lang.String getName()
public void setName(java.lang.String name)
name
- the name to setpublic int getNumRules()
public void setNumRules(int numRules)
numRules
- the numRules to setpublic java.util.ArrayList<AutomaticRule> getListRules()
public void addListRules(AutomaticRule rule)
rule
- to add to the list of rulespublic void updateListRules(AutomaticRule rule, int pos)
rule
- Rule to updatepos
- Position in the listpublic AutomaticRule getRule(int pos)
pos
- position on the list of rulespublic AutomaticRule getRule(java.lang.String name)
name
- of the rule to search.public void setListRules(java.util.ArrayList<AutomaticRule> listRules)
listRules
- the listRules to setpublic java.lang.String toString()
toString
in class java.lang.Object