Package frc8768.robot.operators
Class Operator
java.lang.Object
frc8768.robot.operators.Operator
- Direct Known Subclasses:
DrivebaseOperator
Abstract class designed for Operators.
Anything universal to operators goes in here.
IMPORTANT: OPERATORS ARE THREADED! For every operator a thread is made. It will process one operator without stalling other operators.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
Operator
Operator constructor.- Parameters:
name
- The name of the operator.
-
-
Method Details
-
init
public void init()Start the thread, do not call this method more than once per-operator. -
runLoop
public void runLoop()While loop wrapper -
run
public abstract void run()The operator-specific code -
reviveThread
public void reviveThread()Should an essential subsystem's thread die, restart it. -
isAlive
public boolean isAlive()Check thread status- Returns:
- output of
Thread
isAlive() function for the op thread
-