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

com.foursoft.vecmodel.vec120.AbstractVecPartWithSubComponentsRoleAssert 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;
import org.assertj.core.util.Objects;

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

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

  /**
   * Verifies that the actual VecPartWithSubComponentsRole's partStructureSpecification is equal to the given one.
   * @param partStructureSpecification the given partStructureSpecification to compare the actual VecPartWithSubComponentsRole's partStructureSpecification to.
   * @return this assertion object.
   * @throws AssertionError - if the actual VecPartWithSubComponentsRole's partStructureSpecification is not equal to the given one.
   */
  public S hasPartStructureSpecification(VecPartStructureSpecification partStructureSpecification) {
    // check that actual VecPartWithSubComponentsRole we want to make assertions on is not null.
    isNotNull();

    // overrides the default error message with a more explicit one
    String assertjErrorMessage = "\nExpecting partStructureSpecification of:\n  <%s>\nto be:\n  <%s>\nbut was:\n  <%s>";

    // null safe check
    VecPartStructureSpecification actualPartStructureSpecification = actual.getPartStructureSpecification();
    if (!Objects.areEqual(actualPartStructureSpecification, partStructureSpecification)) {
      failWithMessage(assertjErrorMessage, actual, partStructureSpecification, actualPartStructureSpecification);
    }

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

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

    // check that given VecModuleFamily varargs is not null.
    if (refModuleFamily == null) failWithMessage("Expecting refModuleFamily 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.getRefModuleFamily(), refModuleFamily);

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

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

    // check that given VecModuleFamily collection is not null.
    if (refModuleFamily == null) {
      failWithMessage("Expecting refModuleFamily 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.getRefModuleFamily(), refModuleFamily.toArray());

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

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

    // check that given VecModuleFamily varargs is not null.
    if (refModuleFamily == null) failWithMessage("Expecting refModuleFamily 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.getRefModuleFamily(), refModuleFamily);

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

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

    // check that given VecModuleFamily collection is not null.
    if (refModuleFamily == null) {
      failWithMessage("Expecting refModuleFamily 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.getRefModuleFamily(), refModuleFamily.toArray());

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

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

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

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

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

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

    // check that given VecModuleFamily collection is not null.
    if (refModuleFamily == null) {
      failWithMessage("Expecting refModuleFamily 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.getRefModuleFamily(), refModuleFamily.toArray());

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

  /**
   * Verifies that the actual VecPartWithSubComponentsRole has no refModuleFamily.
   * @return this assertion object.
   * @throws AssertionError if the actual VecPartWithSubComponentsRole's refModuleFamily is not empty.
   */
  public S hasNoRefModuleFamily() {
    // check that actual VecPartWithSubComponentsRole 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 refModuleFamily but had :\n  <%s>";

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

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


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

    // check that given VecModuleList varargs is not null.
    if (refModuleList == null) failWithMessage("Expecting refModuleList 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.getRefModuleList(), refModuleList);

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

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

    // check that given VecModuleList collection is not null.
    if (refModuleList == null) {
      failWithMessage("Expecting refModuleList 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.getRefModuleList(), refModuleList.toArray());

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

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

    // check that given VecModuleList varargs is not null.
    if (refModuleList == null) failWithMessage("Expecting refModuleList 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.getRefModuleList(), refModuleList);

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

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

    // check that given VecModuleList collection is not null.
    if (refModuleList == null) {
      failWithMessage("Expecting refModuleList 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.getRefModuleList(), refModuleList.toArray());

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

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

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

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

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

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

    // check that given VecModuleList collection is not null.
    if (refModuleList == null) {
      failWithMessage("Expecting refModuleList 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.getRefModuleList(), refModuleList.toArray());

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

  /**
   * Verifies that the actual VecPartWithSubComponentsRole has no refModuleList.
   * @return this assertion object.
   * @throws AssertionError if the actual VecPartWithSubComponentsRole's refModuleList is not empty.
   */
  public S hasNoRefModuleList() {
    // check that actual VecPartWithSubComponentsRole 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 refModuleList but had :\n  <%s>";

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

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


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

    // check that given VecOccurrenceOrUsage varargs is not null.
    if (subComponent == null) failWithMessage("Expecting subComponent 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.getSubComponent(), subComponent);

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

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

    // check that given VecOccurrenceOrUsage collection is not null.
    if (subComponent == null) {
      failWithMessage("Expecting subComponent 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.getSubComponent(), subComponent.toArray());

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

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

    // check that given VecOccurrenceOrUsage varargs is not null.
    if (subComponent == null) failWithMessage("Expecting subComponent 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.getSubComponent(), subComponent);

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

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

    // check that given VecOccurrenceOrUsage collection is not null.
    if (subComponent == null) {
      failWithMessage("Expecting subComponent 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.getSubComponent(), subComponent.toArray());

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

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

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

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

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

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

    // check that given VecOccurrenceOrUsage collection is not null.
    if (subComponent == null) {
      failWithMessage("Expecting subComponent 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.getSubComponent(), subComponent.toArray());

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

  /**
   * Verifies that the actual VecPartWithSubComponentsRole has no subComponent.
   * @return this assertion object.
   * @throws AssertionError if the actual VecPartWithSubComponentsRole's subComponent is not empty.
   */
  public S hasNoSubComponent() {
    // check that actual VecPartWithSubComponentsRole 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 subComponent but had :\n  <%s>";

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

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


}