T
- Generic type which this partition holds.public class Partition<T> extends Object implements Iterable<T>
Constructor and Description |
---|
Partition(Date start,
Date end)
Create a Partition for holding elements between the two argument Date
objects.
|
Modifier and Type | Method and Description |
---|---|
void |
add(T o) |
void |
addTotal(int numberToAdd)
Add and int to the Total count for this partition.
|
boolean |
containsDate(Date d)
Checks if a date is within this partition
|
int |
count() |
int |
getCount() |
Date |
getEnd() |
List<T> |
getList()
Same as
list() , Bean property compatible. |
Date |
getStart() |
int |
getTotal() |
boolean |
isContainsClosest() |
Iterator<T> |
iterator() |
List<T> |
list() |
void |
setContainsClosest(boolean containsClosest) |
public boolean containsDate(Date d)
d
- Date to checkpublic Date getStart()
public Date getEnd()
public int count()
public int getCount()
public void add(T o)
o
- element to be added to this partition.public List<T> getList()
list()
, Bean property compatible.public boolean isContainsClosest()
public void setContainsClosest(boolean containsClosest)
containsClosest
- the containsClosest to setpublic void addTotal(int numberToAdd)
numberToAdd
- number to addpublic int getTotal()
Copyright © 2005–2015 IIPC. All rights reserved.