kankan.wheel.widget
Class ItemsRange

java.lang.Object
  extended by kankan.wheel.widget.ItemsRange

public class ItemsRange
extends java.lang.Object

Range for visible items.


Field Summary
private  int count
           
private  int first
           
 
Constructor Summary
ItemsRange()
          Default constructor.
ItemsRange(int first, int count)
          Constructor
 
Method Summary
 boolean contains(int index)
          Tests whether item is contained by range
 int getCount()
          Get items count
 int getFirst()
          Gets number of first item
 int getLast()
          Gets number of last item
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

first

private int first

count

private int count
Constructor Detail

ItemsRange

public ItemsRange()
Default constructor. Creates an empty range


ItemsRange

public ItemsRange(int first,
                  int count)
Constructor

Parameters:
first - the number of first item
count - the count of items
Method Detail

getFirst

public int getFirst()
Gets number of first item

Returns:
the number of the first item

getLast

public int getLast()
Gets number of last item

Returns:
the number of last item

getCount

public int getCount()
Get items count

Returns:
the count of items

contains

public boolean contains(int index)
Tests whether item is contained by range

Parameters:
index - the item number
Returns:
true if item is contained