Class Dimension

    • Constructor Detail

      • Dimension

        public Dimension​(Long width,
                         Long height)
    • Method Detail

      • of

        public static Dimension of​(@Positive
                                   @Positive Long width,
                                   @Positive
                                   @Positive Long height)
      • reduce

        public Dimension reduce()
        Returns the smallest possible dimension with the same aspect ratio.
      • gcd

        protected long gcd​(long a,
                           long b)
      • getWidth

        public Long getWidth()
      • getHeight

        public Long getHeight()
      • equals

        public boolean equals​(@Nullable Object o)
        Overrides:
        equals in class Object
      • canEqual

        protected boolean canEqual​(@Nullable Object other)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object