Class IntegerRange

  • All Implemented Interfaces:
    <>

    public final class IntegerRange
    extends 
    implements <>
    Represents a sequence of integer values, either ascending or descending. The sequence is always inclusive (of the finish value).
    • Constructor Summary

      Constructors 
      Constructor Description
      IntegerRange​(int start, int finish)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean  obj)
      Returns true if the other object is an IntegerRange with the same start and finish values.
      int getFinish()  
      int getStart()  
      int hashCode()  
      <> iterator()
      The main puprose of a range object is to produce an Iterator.
      toString()  
      • Methods inherited from class java.lang.

        , , , , , , ,
      • Methods inherited from interface java.lang.

        ,
    • Constructor Detail

      • IntegerRange

        public IntegerRange​(int start,
                            int finish)
    • Method Detail

      • toString

        public  toString()
        Overrides:
         in class 
      • iterator

        public <> iterator()
        The main puprose of a range object is to produce an Iterator. Since IntegerRange is iterable, it is useful with the Tapestry Loop component, but also with the Java for loop!
        Specified by:
         in interface <>
      • hashCode

        public int hashCode()
        Overrides:
         in class 
      • equals

        public boolean  obj)
        Returns true if the other object is an IntegerRange with the same start and finish values.
        Overrides:
         in class