actions Module¶
These are the actions that can be executed by the users.
-
class
AYABInterface.actions.ActionMetaClass(name, bases, attributes)[source]¶ Bases:
typeMetaclass for the actions.
This class makes sure each
Actionhas tests.If a class is named
MyAction, eachActiongets the methodis_my_action()which returnsFalsefor allActionsexpcept forMyActionit returnsTrue.
-
class
AYABInterface.actions.Action(*arguments)[source]¶ Bases:
objectA base class for actions.
-
__init__(*arguments)[source]¶ Create a new
Action.Parameters: arguments¶ (tuple) – The arguments passed to the action. These are also used to determine equalityand thehash.
-
__weakref__¶ list of weak references to the object (if defined)
-
is_move_carriage_over_left_hall_sensor()¶ Test whether this is a MoveCarriageOverLeftHallSensor.
Return type: bool Returns: False
-
is_move_carriage_to_the_left()¶ Test whether this is a MoveCarriageToTheLeft.
Return type: bool Returns: False
-
is_move_carriage_to_the_right()¶ Test whether this is a MoveCarriageToTheRight.
Return type: bool Returns: False
-
is_move_needles_into_position()¶ Test whether this is a MoveNeedlesIntoPosition.
Return type: bool Returns: False
-
is_switch_carriage_to_mode_kc()¶ Test whether this is a SwitchCarriageToModeKc.
Return type: bool Returns: False
-
-
class
AYABInterface.actions.SwitchCarriageToModeKc(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user switches the mode of the carriage to KC.
-
class
AYABInterface.actions.SwitchCarriageToModeNl(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user switches the mode of the carriage to NL.
-
class
AYABInterface.actions.MoveCarriageOverLeftHallSensor(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user moves the carriage over the left hall sensor.
-
class
AYABInterface.actions.MoveCarriageToTheLeft(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user moves the carriage to the left.
-
class
AYABInterface.actions.MoveCarriageToTheRight(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user moves the carriage to the right.
-
class
AYABInterface.actions.PutColorInNutA(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user puts a color into nut A.
-
class
AYABInterface.actions.PutColorInNutB(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user puts a color into nut B.
-
class
AYABInterface.actions.MoveNeedlesIntoPosition(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user moves needles into position.
-
class
AYABInterface.actions.SwitchOffMachine(*arguments)[source]¶ Bases:
AYABInterface.actions.ActionThe user switches off the machine.