class AbstractPeriodAssert<SELF extends AbstractPeriodAssert<SELF>> extends AbstractAssert<SELF, Period> {

  /**
   * Creates a new <code>{@link org.assertj.core.api.AbstractPeriodAssert}</code>
   * @param period the actual value to verify
   * @param selfType the "self type"
   */
  protected AbstractPeriodAssert(Period period, Class<?> selfType) {
    super(period, selfType);
  }

  /**
   * Verifies that the actual {@code Period} has the given years.
   * <p>
   * Example :
   * <pre><code class='java'> // assertion will pass
   * assertThat(Period.ofYears(5)).hasYears(5);
   *
   * // assertion will fail
   * assertThat(Period.ofYears(5)).hasYears(1);</code></pre>
   *
   * @param expectedYears the expected years value
   * @return this assertion object
   * @throws AssertionError if the actual {@code Period} is {@code null}
   * @throws AssertionError if the actual {@code Period} does not have the given years
   * @since 3.17.0
   */
  public SELF hasYears(int expectedYears) {
    isNotNull();
    int actualYears = actual.getYears();
    if (expectedYears != actualYears) {
      throw Failures.instance().failure(info, shouldHaveYears(actual, actualYears, expectedYears), actualYears, expectedYears);
    }
    return myself;
  }

  /**
   * Verifies that the actual {@code Period} has the given months.
   * <p>
   * Example :
   * <pre><code class='java'> // assertion will pass
   * assertThat(Period.ofMonths(5)).hasMonths(5);
   *
   * // assertion will fail
   * assertThat(Period.ofMonths(5)).hasMonths(1);</code></pre>
   *
   * @param expectedMonths the expected months value
   * @return this assertion object
   * @throws AssertionError if the actual {@code Period} is {@code null}
   * @throws AssertionError if the actual {@code Period} does not have the given months
   * @since 3.17.0
   */
  public SELF hasMonths(int expectedMonths) {
    isNotNull();
    int actualMonths = actual.getMonths();
    if (expectedMonths != actualMonths) {
      throw Failures.instance().failure(info, shouldHaveMonths(actual, actualMonths, expectedMonths), actualMonths,
                                        expectedMonths);
    }
    return myself;
  }

  /**
   * Verifies that the actual {@code Period} has the given days.
   * <p>
   * Example :
   * <pre><code class='java'> // assertion will pass
   * assertThat(Period.ofDays(5)).hasDays(5);
   *
   * // assertion will fail
   * assertThat(Period.ofDays(5)).hasDays(1);</code></pre>
   *
   * @param expectedDays the expected days value
   * @return this assertion object
   * @throws AssertionError if the actual {@code Period} is {@code null}
   * @throws AssertionError if the actual {@code Period} does not have the given days
   * @since 3.17.0
   */
  public SELF hasDays(int expectedDays) {
    isNotNull();
    int actualDays = actual.getDays();
    if (expectedDays != actualDays) {
      throw Failures.instance().failure(info, shouldHaveDays(actual, actualDays, expectedDays), actualDays, expectedDays);
    }
    return myself;
  }

  /**
   * Verifies that the actual {@code Period} is positive (i.e. is greater than {@link Period#ZERO}).
   * <p>
   * Example :
   * <pre><code class='java'> // assertion will pass
   * assertThat(Period.ofMonths(5)).isPositive();
   *
   * // assertion will fail
   * assertThat(Period.ofMonths(-2)).isPositive();</code></pre>
   * @return this assertion object
   * @throws AssertionError if the actual {@code Period} is {@code null}
   * @throws AssertionError if the actual {@code Period} is not greater than {@link Period#ZERO}
   * @since 3.17.0
   */
  public SELF isPositive() {
    isNotNull();
    boolean negative = actual.isNegative();
    if (negative || Period.ZERO.equals(actual)) throw Failures.instance().failure(info, shouldBePositive(actual));
    return myself;
  }

  /**
   * Verifies that the actual {@code Period} is negative (i.e. is less than {@link Period#ZERO}).
   * <p>
   * Example :
   * <pre><code class='java'> // assertion will pass
   * assertThat(Period.ofMonths(-5)).isNegative();
   *
   * // assertion will fail
   * assertThat(Period.ofMonths(2)).isNegative();</code></pre>
   * @return this assertion object
   * @throws AssertionError if the actual {@code Period} is {@code null}
   * @throws AssertionError if the actual {@code Period} is not greater than {@link Period#ZERO}
   * @since 3.17.0
   */
  public SELF isNegative() {<FILL_FUNCTION_BODY>}
}

    isNotNull();
    boolean negative = actual.isNegative();
    if (!negative || Period.ZERO.equals(actual)) throw Failures.instance().failure(info, shouldBeNegative(actual));
    return myself;
  
<methods>public ASSERT asInstanceOf(InstanceOfAssertFactory<?,ASSERT>) ,public AbstractListAssert<?,List<?>,java.lang.Object,ObjectAssert<java.lang.Object>> asList() ,public AbstractStringAssert<?> asString() ,public SELF describedAs(org.assertj.core.description.Description) ,public java.lang.String descriptionText() ,public SELF doesNotHave(Condition<? super java.time.Period>) ,public SELF doesNotHaveSameClassAs(java.lang.Object) ,public SELF doesNotHaveSameHashCodeAs(java.lang.Object) ,public SELF doesNotHaveToString(java.lang.String) ,public transient SELF doesNotHaveToString(java.lang.String, java.lang.Object[]) ,public boolean equals(java.lang.Object) ,public org.assertj.core.api.WritableAssertionInfo getWritableAssertionInfo() ,public SELF has(Condition<? super java.time.Period>) ,public SELF hasSameClassAs(java.lang.Object) ,public SELF hasSameHashCodeAs(java.lang.Object) ,public SELF hasToString(java.lang.String) ,public transient SELF hasToString(java.lang.String, java.lang.Object[]) ,public int hashCode() ,public SELF is(Condition<? super java.time.Period>) ,public SELF isEqualTo(java.lang.Object) ,public SELF isExactlyInstanceOf(Class<?>) ,public transient SELF isIn(java.lang.Object[]) ,public SELF isIn(Iterable<?>) ,public SELF isInstanceOf(Class<?>) ,public transient SELF isInstanceOfAny(Class<?>[]) ,public SELF isInstanceOfSatisfying(Class<T>, Consumer<T>) ,public SELF isNot(Condition<? super java.time.Period>) ,public SELF isNotEqualTo(java.lang.Object) ,public SELF isNotExactlyInstanceOf(Class<?>) ,public transient SELF isNotIn(java.lang.Object[]) ,public SELF isNotIn(Iterable<?>) ,public SELF isNotInstanceOf(Class<?>) ,public transient SELF isNotInstanceOfAny(Class<?>[]) ,public SELF isNotNull() ,public transient SELF isNotOfAnyClassIn(Class<?>[]) ,public SELF isNotSameAs(java.lang.Object) ,public void isNull() ,public transient SELF isOfAnyClassIn(Class<?>[]) ,public SELF isSameAs(java.lang.Object) ,public SELF matches(Predicate<? super java.time.Period>) ,public SELF matches(Predicate<? super java.time.Period>, java.lang.String) ,public transient SELF overridingErrorMessage(java.lang.String, java.lang.Object[]) ,public SELF overridingErrorMessage(Supplier<java.lang.String>) ,public SELF satisfies(Condition<? super java.time.Period>) ,public final transient SELF satisfies(Consumer<? super java.time.Period>[]) ,public final transient SELF satisfies(ThrowingConsumer<? super java.time.Period>[]) ,public final transient SELF satisfiesAnyOf(Consumer<? super java.time.Period>[]) ,public final transient SELF satisfiesAnyOf(ThrowingConsumer<? super java.time.Period>[]) ,public static void setCustomRepresentation(org.assertj.core.presentation.Representation) ,public static void setDescriptionConsumer(Consumer<org.assertj.core.description.Description>) ,public static void setPrintAssertionsDescription(boolean) ,public SELF usingComparator(Comparator<? super java.time.Period>) ,public SELF usingComparator(Comparator<? super java.time.Period>, java.lang.String) ,public SELF usingDefaultComparator() ,public transient SELF withFailMessage(java.lang.String, java.lang.Object[]) ,public SELF withFailMessage(Supplier<java.lang.String>) ,public SELF withRepresentation(org.assertj.core.presentation.Representation) ,public SELF withThreadDumpOnError() <variables>private static final java.lang.String ORG_ASSERTJ,protected final non-sealed java.time.Period actual,org.assertj.core.error.AssertionErrorCreator assertionErrorCreator,org.assertj.core.internal.Conditions conditions,static org.assertj.core.presentation.Representation customRepresentation,private static Consumer<org.assertj.core.description.Description> descriptionConsumer,public org.assertj.core.api.WritableAssertionInfo info,protected final non-sealed SELF myself,protected org.assertj.core.internal.Objects objects,static boolean printAssertionsDescription,public static boolean throwUnsupportedExceptionOnEquals