All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.foursoft.vecmodel.vec120.AbstractVecSlotReferenceAssert Maven / Gradle / Ivy

There is a newer version: 1.5.2
Show newest version
package com.foursoft.vecmodel.vec120;

import org.assertj.core.internal.Iterables;

/**
 * Abstract base class for {@link VecSlotReference} specific assertions - Generated by CustomAssertionGenerator.
 */
@javax.annotation.Generated(value="assertj-assertions-generator")
public abstract class AbstractVecSlotReferenceAssert, A extends VecSlotReference> extends AbstractVecAbstractSlotReferenceAssert {

  /**
   * Creates a new {@link AbstractVecSlotReferenceAssert} to make assertions on actual VecSlotReference.
   * @param actual the VecSlotReference we want to make assertions on.
   */
  protected AbstractVecSlotReferenceAssert(A actual, Class selfType) {
    super(actual, selfType);
  }

  /**
   * Verifies that the actual VecSlotReference's cavityReferences contains the given VecCavityReference elements.
   * @param cavityReferences the given elements that should be contained in actual VecSlotReference's cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences does not contain all given VecCavityReference elements.
   */
  public S hasCavityReferences(VecCavityReference... cavityReferences) {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // check that given VecCavityReference varargs is not null.
    if (cavityReferences == null) failWithMessage("Expecting cavityReferences parameter not to be null.");

    // check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
    Iterables.instance().assertContains(info, actual.getCavityReferences(), cavityReferences);

    // return the current assertion for method chaining
    return myself;
  }

  /**
   * Verifies that the actual VecSlotReference's cavityReferences contains the given VecCavityReference elements in Collection.
   * @param cavityReferences the given elements that should be contained in actual VecSlotReference's cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences does not contain all given VecCavityReference elements.
   */
  public S hasCavityReferences(java.util.Collection cavityReferences) {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // check that given VecCavityReference collection is not null.
    if (cavityReferences == null) {
      failWithMessage("Expecting cavityReferences parameter not to be null.");
      return myself; // to fool Eclipse "Null pointer access" warning on toArray.
    }

    // check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
    Iterables.instance().assertContains(info, actual.getCavityReferences(), cavityReferences.toArray());

    // return the current assertion for method chaining
    return myself;
  }

  /**
   * Verifies that the actual VecSlotReference's cavityReferences contains only the given VecCavityReference elements and nothing else in whatever order.
   * @param cavityReferences the given elements that should be contained in actual VecSlotReference's cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences does not contain all given VecCavityReference elements.
   */
  public S hasOnlyCavityReferences(VecCavityReference... cavityReferences) {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // check that given VecCavityReference varargs is not null.
    if (cavityReferences == null) failWithMessage("Expecting cavityReferences parameter not to be null.");

    // check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
    Iterables.instance().assertContainsOnly(info, actual.getCavityReferences(), cavityReferences);

    // return the current assertion for method chaining
    return myself;
  }

  /**
   * Verifies that the actual VecSlotReference's cavityReferences contains only the given VecCavityReference elements in Collection and nothing else in whatever order.
   * @param cavityReferences the given elements that should be contained in actual VecSlotReference's cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences does not contain all given VecCavityReference elements.
   */
  public S hasOnlyCavityReferences(java.util.Collection cavityReferences) {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // check that given VecCavityReference collection is not null.
    if (cavityReferences == null) {
      failWithMessage("Expecting cavityReferences parameter not to be null.");
      return myself; // to fool Eclipse "Null pointer access" warning on toArray.
    }

    // check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
    Iterables.instance().assertContainsOnly(info, actual.getCavityReferences(), cavityReferences.toArray());

    // return the current assertion for method chaining
    return myself;
  }

  /**
   * Verifies that the actual VecSlotReference's cavityReferences does not contain the given VecCavityReference elements.
   *
   * @param cavityReferences the given elements that should not be in actual VecSlotReference's cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences contains any given VecCavityReference elements.
   */
  public S doesNotHaveCavityReferences(VecCavityReference... cavityReferences) {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // check that given VecCavityReference varargs is not null.
    if (cavityReferences == null) failWithMessage("Expecting cavityReferences parameter not to be null.");

    // check with standard error message (use overridingErrorMessage before contains to set your own message).
    Iterables.instance().assertDoesNotContain(info, actual.getCavityReferences(), cavityReferences);

    // return the current assertion for method chaining
    return myself;
  }

  /**
   * Verifies that the actual VecSlotReference's cavityReferences does not contain the given VecCavityReference elements in Collection.
   *
   * @param cavityReferences the given elements that should not be in actual VecSlotReference's cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences contains any given VecCavityReference elements.
   */
  public S doesNotHaveCavityReferences(java.util.Collection cavityReferences) {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // check that given VecCavityReference collection is not null.
    if (cavityReferences == null) {
      failWithMessage("Expecting cavityReferences parameter not to be null.");
      return myself; // to fool Eclipse "Null pointer access" warning on toArray.
    }

    // check with standard error message (use overridingErrorMessage before contains to set your own message).
    Iterables.instance().assertDoesNotContain(info, actual.getCavityReferences(), cavityReferences.toArray());

    // return the current assertion for method chaining
    return myself;
  }

  /**
   * Verifies that the actual VecSlotReference has no cavityReferences.
   * @return this assertion object.
   * @throws AssertionError if the actual VecSlotReference's cavityReferences is not empty.
   */
  public S hasNoCavityReferences() {
    // check that actual VecSlotReference we want to make assertions on is not null.
    isNotNull();

    // we override the default error message with a more explicit one
    String assertjErrorMessage = "\nExpecting :\n  <%s>\nnot to have cavityReferences but had :\n  <%s>";

    // check
    if (actual.getCavityReferences().iterator().hasNext()) {
      failWithMessage(assertjErrorMessage, actual, actual.getCavityReferences());
    }

    // return the current assertion for method chaining
    return myself;
  }


}