Interface WholeNumbers<NUMBER extends java.lang.Number>

  • All Known Implementing Classes:
    Bytes, Integers, Longs, Shorts

    public interface WholeNumbers<NUMBER extends java.lang.Number>
    • Method Detail

      • isEven

        boolean isEven​(NUMBER number)
      • isOdd

        default boolean isOdd​(NUMBER number)
      • assertIsOdd

        default void assertIsOdd​(AssertionInfo info,
                                 NUMBER actual)
        Asserts that the actual value is odd.
        Parameters:
        info - contains information about the assertion.
        actual - the actual value.
        Throws:
        java.lang.AssertionError - if the actual value is null.
      • assertIsEven

        default void assertIsEven​(AssertionInfo info,
                                  NUMBER actual)
        Asserts that the actual value is even.
        Parameters:
        info - contains information about the assertion.
        actual - the actual value.
        Throws:
        java.lang.AssertionError - if the actual value is null.