Class ShouldHaveSize

  • All Implemented Interfaces:
    org.assertj.core.error.ErrorMessageFactory

    public class ShouldHaveSize
    extends org.assertj.core.error.BasicErrorMessageFactory
    Creates an error message indicating that an assertion that verifies that a value have certain size failed.
    Author:
    Joel Costigliola
    • Field Summary

      • Fields inherited from class org.assertj.core.error.BasicErrorMessageFactory

        arguments, format
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private ShouldHaveSize​(Object actual, long actualSize, long expectedSize)  
    • Constructor Detail

      • ShouldHaveSize

        private ShouldHaveSize​(Object actual,
                               long actualSize,
                               long expectedSize)
    • Method Detail

      • shouldHaveSize

        public static org.assertj.core.error.ErrorMessageFactory shouldHaveSize​(Object actual,
                                                                                long actualSize,
                                                                                long expectedSize)
        Creates a new ShouldHaveSize.
        Parameters:
        actual - the actual value in the failed assertion.
        actualSize - the size of actual.
        expectedSize - the expected size.
        Returns:
        the created ErrorMessageFactory.