diff --git a/wpilibj/athena.gradle b/wpilibj/athena.gradle index 998e1599c0..d97c04ff46 100644 --- a/wpilibj/athena.gradle +++ b/wpilibj/athena.gradle @@ -111,6 +111,9 @@ task wpilibjSources(type: Jar, dependsOn: classes) { task javadoc(type: Javadoc, overwrite: true) { source sourceSets.athena.allJava, sourceSets.shared.allJava classpath = files([sourceSets.athena.compileClasspath, sourceSets.shared.compileClasspath]) + javadoc.options.links("http://docs.oracle.com/javase/8/docs/api/") + options.addStringOption "tag", "pre:a:Pre-Condition" +// options.addStringOption('Xdoclint:accessibility,syntax,reference,html', '-quiet') } task wpilibjJavadoc(type: Jar, dependsOn: javadoc) { diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANJaguar.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANJaguar.java index 43e18bd1a7..0566df2ec1 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANJaguar.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANJaguar.java @@ -1157,7 +1157,7 @@ public class CANJaguar implements MotorSafety, PIDOutput, CANSpeedController { /** * Return whether the controller is enabled. * - * @returns true if enabled. + * @return true if enabled. */ public boolean isEnabled() { return m_controlEnabled; diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANTalon.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANTalon.java index d03fd7fd40..2a5b230e86 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANTalon.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/CANTalon.java @@ -450,7 +450,7 @@ public class CANTalon implements MotorSafety, PIDOutput, PIDSource, CANSpeedCont return CanTalonJNI.intp_value(valuep); } /** - * @param which feedback sensor to check it if is connected. + * @param feedbackDevice which feedback sensor to check it if is connected. * @return status of caller's specified sensor type. */ public FeedbackDeviceStatus isSensorPresent(FeedbackDevice feedbackDevice) { diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/InterruptHandlerFunction.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/InterruptHandlerFunction.java index f507b96a60..f09f2c5c6a 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/InterruptHandlerFunction.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/InterruptHandlerFunction.java @@ -12,7 +12,7 @@ import edu.wpi.first.wpilibj.hal.InterruptJNI.InterruptJNIHandlerFunction; /** * It is recommended that you use this class in conjunction with classes from * {@link java.util.concurrent.atomic} as these objects are all thread safe. - *$ + * * @author Jonathan Leitschuh * * @param The type of the parameter that should be returned to the the @@ -40,7 +40,7 @@ public abstract class InterruptHandlerFunction { /** * This method is run every time an interrupt is fired. *$ - * @param interruptAssertedMask + * @param interruptAssertedMask Interrupt Mask * @param param The parameter provided by overriding the * {@link #overridableParameter()} method. */ diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Joystick.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Joystick.java index 68ee35ba72..b526f247b7 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Joystick.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Joystick.java @@ -422,7 +422,7 @@ public class Joystick extends GenericHID { /** * Get the value of isXbox for the current joystick. *$ - * @param value A boolean that is true if the controller is an xbox + * @return A boolean that is true if the controller is an xbox * controller. */ public boolean getIsXbox() { @@ -432,7 +432,7 @@ public class Joystick extends GenericHID { /** * Get the HID type of the current joystick. *$ - * @param value The HID type value of the current joystick. + * @return The HID type value of the current joystick. */ public int getType() { return m_ds.getJoystickType(m_port); @@ -441,7 +441,7 @@ public class Joystick extends GenericHID { /** * Get the name of the current joystick. *$ - * @param value The name of the current joystick. + * @return The name of the current joystick. */ public String getName() { return m_ds.getJoystickName(m_port); diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Notifier.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Notifier.java index e407ef6bd2..492a9abadc 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Notifier.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Notifier.java @@ -88,7 +88,7 @@ public class Notifier { /** * Create a Notifier for timer event notification. *$ - * @param handler The handler is called at the notification time which is set + * @param run The handler that is called at the notification time which is set * using StartSingle or StartPeriodic. */ public Notifier(Runnable run) { diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/RobotDrive.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/RobotDrive.java index 917ee446ab..51b4827cc7 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/RobotDrive.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/RobotDrive.java @@ -184,7 +184,7 @@ public class RobotDrive implements MotorSafety { /** * Drive the motors at "outputMagnitude" and "curve". * Both outputMagnitude and curve are -1.0 to +1.0 values, where 0.0 - * represents stopped and not turning. curve < 0 will turn left and curve > 0 + * represents stopped and not turning. {@literal curve < 0 will turn left and curve > 0} * will turn right. * * The algorithm for steering provides a constant turn radius for any normal @@ -196,7 +196,7 @@ public class RobotDrive implements MotorSafety { * @param outputMagnitude The speed setting for the outside wheel in a turn, * forward or backwards, +1 to -1. * @param curve The rate of turn, constant for different forward speeds. Set - * curve < 0 for left turn or curve > 0 for right turn. + * {@literal curve < 0 for left turn or curve > 0 for right turn.} * Set curve = e^(-r/w) to get a turn radius r for wheelbase w of your robot. * Conversely, turn radius r = -ln(curve)*w for a given value of curve and * wheelbase w. diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SPI.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SPI.java index fded29e50c..108c640cae 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SPI.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SPI.java @@ -202,8 +202,10 @@ public class SPI extends SensorBase { * and initiates a transfer. If false, this function assumes that data * is already in the receive FIFO from a previous write. * - * @param received The buffer to be filled with the received data. Must be + * @param dataReceived The buffer to be filled with the received data. Must be * created using ByteBuffer.allocateDirect(). + * + * @param size The length of the transaction, in bytes */ public int read(boolean initiate, ByteBuffer dataReceived, int size) { if (!dataReceived.isDirect()) diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SensorBase.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SensorBase.java index 98fa971a1c..a8d8120c22 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SensorBase.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/SensorBase.java @@ -176,7 +176,7 @@ public abstract class SensorBase { // TODO: Refactor * Verify that the PDP module number is within limits. module numbers are * 0-based. *$ - * @param channel The module number to check. + * @param module The module number to check. */ protected static void checkPDPModule(final int module) { if (module < 0 || module > kPDPModules) { diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Solenoid.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Solenoid.java index a3610da940..fa4a82f12f 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Solenoid.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/Solenoid.java @@ -108,7 +108,7 @@ public class Solenoid extends SolenoidBase implements LiveWindowSendable { * Check if solenoid is blacklisted. If a solenoid is shorted, it is added to * the blacklist and disabled until power cycle, or until faults are cleared. * - * @see clearAllPCMStickyFaults() + * @see #clearAllPCMStickyFaults() * * @return If solenoid is disabled due to short. */ diff --git a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/image/BinaryImage.java b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/image/BinaryImage.java index 5b1354e7a1..030f268461 100644 --- a/wpilibj/src/athena/java/edu/wpi/first/wpilibj/image/BinaryImage.java +++ b/wpilibj/src/athena/java/edu/wpi/first/wpilibj/image/BinaryImage.java @@ -128,7 +128,6 @@ public class BinaryImage extends MonoImage { * Vision Concepts manual. * @param erosions the number of erosions to perform * @return a BinaryImage after applying the filter - * @throws NIVisionException */ public BinaryImage removeSmallObjects(boolean connectivity8, int erosions) throws NIVisionException { @@ -150,7 +149,6 @@ public class BinaryImage extends MonoImage { * Vision Concepts manual. * @param erosions the number of erosions to perform * @return a BinaryImage after applying the filter - * @throws NIVisionException */ public BinaryImage removeLargeObjects(boolean connectivity8, int erosions) throws NIVisionException { diff --git a/wpilibj/src/shared/java/edu/wpi/first/wpilibj/Controller.java b/wpilibj/src/shared/java/edu/wpi/first/wpilibj/Controller.java index 6e39298bf3..b3a840d1f9 100644 --- a/wpilibj/src/shared/java/edu/wpi/first/wpilibj/Controller.java +++ b/wpilibj/src/shared/java/edu/wpi/first/wpilibj/Controller.java @@ -19,7 +19,7 @@ interface Controller { /** * Stops the control loop from running until explicitly re-enabled by calling - * {@link enable()}. + * {@link #enable()}. */ public void disable(); } diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/MotorEncoderTest.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/MotorEncoderTest.java index 5758c694a5..9559ef40e2 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/MotorEncoderTest.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/MotorEncoderTest.java @@ -144,7 +144,7 @@ public class MotorEncoderTest extends AbstractComsSetup { } /** - * Tests to see if you set the speed to something not <= 1.0 if the code + * Tests to see if you set the speed to something not {@literal <=} 1.0 if the code * appropriately throttles the value */ @Test @@ -155,7 +155,7 @@ public class MotorEncoderTest extends AbstractComsSetup { } /** - * Tests to see if you set the speed to something not >= -1.0 if the code + * Tests to see if you set the speed to something not {@literal >=} -1.0 if the code * appropriately throttles the value */ @Test diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/can/package-info.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/can/package-info.java index 1a9b6db2a5..c671bc6ed5 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/can/package-info.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/can/package-info.java @@ -3,7 +3,7 @@ * modes and with each supported positional input. Different setup parameters * are provided in each Test class. All test classes that want to take advantage * of the default test setup frameworks in place should extend - * {@link AbstractCANTest} + * {@link edu.wpi.first.wpilibj.can.AbstractCANTest AbstractCANTest} *$ */ package edu.wpi.first.wpilibj.can; \ No newline at end of file diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/AnalogCrossConnectFixture.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/AnalogCrossConnectFixture.java index 54b03729ec..c147d97ae2 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/AnalogCrossConnectFixture.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/AnalogCrossConnectFixture.java @@ -70,7 +70,7 @@ public abstract class AnalogCrossConnectFixture implements ITestFixture { } /** - * @return + * @return Analog Output */ final public AnalogOutput getOutput() { initialize(); diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/MotorEncoderFixture.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/MotorEncoderFixture.java index 3ae5e98e2a..069300aefd 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/MotorEncoderFixture.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/fixtures/MotorEncoderFixture.java @@ -51,7 +51,7 @@ public abstract class MotorEncoderFixture implements * Constructor should only be called from outside this class if the Speed * controller is not also an implementation of PWM interface *$ - * @return + * @return SpeedController */ abstract protected T giveSpeedController(); @@ -59,7 +59,7 @@ public abstract class MotorEncoderFixture implements * Where the implementer of this class should pass one of the digital inputs
* CONSTRUCTOR SHOULD NOT BE CALLED FROM OUTSIDE THIS CLASS! *$ - * @return + * @return DigitalInput */ abstract protected DigitalInput giveDigitalInputA(); diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeCounterSource.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeCounterSource.java index ad91b2a9b1..cd76897dd3 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeCounterSource.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeCounterSource.java @@ -10,7 +10,7 @@ import edu.wpi.first.wpilibj.DigitalOutput; import edu.wpi.first.wpilibj.Timer; /** - * @file FakeCounterSource.java Simulates an encoder for testing purposes + * Simulates an encoder for testing purposes * @author Ryan O'Meara */ public class FakeCounterSource { diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeEncoderSource.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeEncoderSource.java index d3814504b8..a79e7cd09c 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeEncoderSource.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakeEncoderSource.java @@ -10,7 +10,7 @@ import edu.wpi.first.wpilibj.DigitalOutput; import edu.wpi.first.wpilibj.Timer; /** - * @file FakeEncoderSource.java Emulates a quadrature encoder + * Emulates a quadrature encoder * @author Ryan O'Meara */ public class FakeEncoderSource { diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakePotentiometerSource.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakePotentiometerSource.java index 19c9fa736f..6d4d5ef8ca 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakePotentiometerSource.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mockhardware/FakePotentiometerSource.java @@ -64,7 +64,7 @@ public class FakePotentiometerSource { /** * Returns the currently set angle *$ - * @return + * @return the current angle */ public double getAngle() { double voltage = output.getVoltage(); diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mocks/MockCommand.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mocks/MockCommand.java index 669bc44db2..210e9df761 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mocks/MockCommand.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/mocks/MockCommand.java @@ -75,7 +75,7 @@ public class MockCommand extends Command { } /** - * @param set what value the isFinished method will return + * @param hasFinished set what value the isFinished method will return */ public void setHasFinished(boolean hasFinished) { this.hasFinished = hasFinished; diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/AbstractTestSuite.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/AbstractTestSuite.java index 67d8b7efdb..171159d514 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/AbstractTestSuite.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/AbstractTestSuite.java @@ -38,6 +38,8 @@ public abstract class AbstractTestSuite { *$ * @return the list of classes listed in the * @SuiteClasses({TestClass1.class, ...}) annotation. + * @throws RuntimeException If the @SuiteClasses annotation is + * missing. */ protected List> getAnnotatedTestClasses() { SuiteClasses annotation = getClass().getAnnotation(SuiteClasses.class); @@ -52,11 +54,6 @@ public abstract class AbstractTestSuite { return classes; } - /** - *$ - * @param check - * @return - */ private boolean areAnySuperClassesOfTypeAbstractTestSuite(Class check) { while (check != null) { if (check.equals(AbstractTestSuite.class)) { @@ -88,10 +85,6 @@ public abstract class AbstractTestSuite { } } - /** - * @param regex - * @return - */ protected List getMethodMatching(final String regex) { List classMethodPairs = new Vector(); // Get all of the test classes @@ -160,7 +153,7 @@ public abstract class AbstractTestSuite { /** * Retrieves all of the classes listed in the - * @SuiteClasses annotation that match the given regex text. + * @SuiteClasses annotation that match the given regex text. *$ * @param regex the text pattern to retrieve. * @param runningList the running list of classes to prevent recursion @@ -178,7 +171,7 @@ public abstract class AbstractTestSuite { /** * Retrieves all of the classes listed in the - * @SuiteClasses annotation that match the given regex text. + * @SuiteClasses annotation that match the given regex text. *$ * @param regex the text pattern to retrieve. * @return The list of classes matching the regex pattern @@ -252,10 +245,10 @@ public abstract class AbstractTestSuite { /** * Retrieves all of the classes listed in the - * @SuiteClasses annotation. + * @SuiteClasses annotation. *$ - * @return - * @throws InitializationError If the @SuiteClasses annotation is + * @return List of SuiteClasses + * @throws RuntimeException If the @SuiteClasses annotation is * missing. */ public List> getAllClasses() { @@ -264,10 +257,10 @@ public abstract class AbstractTestSuite { /** * Gets the name of all of the classes listed within the - * @SuiteClasses annotation. + * @SuiteClasses annotation. *$ * @return the list of classes. - * @throws InitializationError If the @SuiteClasses annotation is + * @throws RuntimeException If the @SuiteClasses annotation is * missing. */ public List getAllClassName() { diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/RepeatRule.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/RepeatRule.java index c8753090ad..45bce27cb0 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/RepeatRule.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/RepeatRule.java @@ -18,11 +18,9 @@ import org.junit.runners.model.Statement; * This JUnit Rule allows you to apply this rule to any test to allow it to run * multiple times. This is important if you have a test that fails only * "sometimes" and needs to be rerun to find the issue. - *$ - * This code was originally found here: Running JUnit Tests Repeatedly Without Loops - *$ + * + * This code was originally found here: Running JUnit Tests Repeatedly Without Loops + * * @author Frank Appel */ public class RepeatRule implements TestRule { diff --git a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/TestBench.java b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/TestBench.java index 899bf6d319..31f8b23ac7 100644 --- a/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/TestBench.java +++ b/wpilibjIntegrationTests/src/main/java/edu/wpi/first/wpilibj/test/TestBench.java @@ -340,7 +340,7 @@ public final class TestBench { * Return a single Collection containing all of the DIOCrossConnectFixtures in * all two pair combinations *$ - * @return + * @return pairs of DIOCrossConnectFixtures */ public Collection getDIOCrossConnectCollection() { Collection pairs = new ArrayList();