Quote:
Originally Posted by lethc
Why?
|
I thought the same at first (when I started writing this), and figured I could use super for most of the functions I needed. But I realized as I was writing this that each function that will get called and actually DOES anything needs to be @Overrid and pointed to all three Talons. Unless there is a function in CANTalon that simply IDENTIFIES the CANTalons, that doesn't DO anything that needs to be overridden (eg public String getType() {return "CANTalon"}, it would be simpler. He has a point, there is no reason TO implement CANTalons unless there is said identifying function
Quote:
Originally Posted by notmattlythgoe
The SpeedController is the base interface for all of the motor controllers. This way you know you are implementing all of the stuff that needs implemented. Really it should just be calling the same method that you're implementing for each of the CANTalons.
|
CANTalon does implement SpeedController, by extending it my class inherits all the functions, plus the way CANTalons identify themselves
Ultimately, it comes to not having to call the super constructor, and I will go with notmattlythgoe that directly implementing SpeedController is better