|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.fortuna.ical4j.model.PeriodList
public class PeriodList
$Id: PeriodList.java,v 1.33 2011/03/19 06:27:42 fortuna Exp $ [23-Apr-2004]
Defines a list of iCalendar periods. NOTE: By implementing the
java.util.SortedSet
interface period lists will always be
sorted according to natural ordering.
Constructor Summary | |
---|---|
PeriodList()
Default constructor. |
|
PeriodList(boolean utc)
|
|
PeriodList(boolean utc,
boolean unmodifiable)
|
|
PeriodList(java.lang.String aValue)
Parses the specified string representation to create a list of periods. |
Method Summary | |
---|---|
boolean |
add(java.lang.Object period)
Overrides superclass to throw an IllegalArgumentException
where argument is not a net.fortuna.ical4j.model.Period . |
boolean |
add(Period period)
Add a period to the list. |
PeriodList |
add(PeriodList periods)
A convenience method that combines all the periods in the specified list to this list. |
boolean |
addAll(java.util.Collection arg0)
|
void |
clear()
|
boolean |
contains(java.lang.Object o)
|
boolean |
containsAll(java.util.Collection arg0)
|
boolean |
equals(java.lang.Object obj)
|
TimeZone |
getTimeZone()
|
int |
hashCode()
|
boolean |
isEmpty()
|
boolean |
isUtc()
Indicates whether this list is in local or UTC format. |
java.util.Iterator |
iterator()
|
PeriodList |
normalise()
Returns a normalised version of this period list. |
boolean |
remove(java.lang.Object o)
|
boolean |
remove(Period period)
Remove a period from the list. |
boolean |
removeAll(java.util.Collection arg0)
|
boolean |
retainAll(java.util.Collection arg0)
|
void |
setTimeZone(TimeZone timeZone)
Applies the specified timezone to all dates in the list. |
void |
setUtc(boolean utc)
Sets whether this list is in UTC or local time format. |
int |
size()
|
PeriodList |
subtract(PeriodList subtractions)
Subtracts the intersection of this list with the specified list of periods from this list and returns the results as a new period list. |
java.lang.Object[] |
toArray()
|
java.lang.Object[] |
toArray(java.lang.Object[] arg0)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public PeriodList()
public PeriodList(boolean utc)
utc
- indicates whether the period list is in UTC timepublic PeriodList(boolean utc, boolean unmodifiable)
utc
- indicates whether the period list is in UTC timepublic PeriodList(java.lang.String aValue) throws java.text.ParseException
aValue
- a string representation of a list of periods
java.text.ParseException
- thrown when an invalid string representation of a period list
is specifiedMethod Detail |
---|
public final java.lang.String toString()
toString
in class java.lang.Object
public final boolean add(Period period)
period
- the period to add
List.add(java.lang.Object)
public final boolean add(java.lang.Object period)
IllegalArgumentException
where argument is not a net.fortuna.ical4j.model.Period
.
add
in interface java.util.Collection
add
in interface java.util.Set
period
- a period to add to the list
java.util.List#add(E)
public final boolean remove(Period period)
period
- the period to remove
List.remove(java.lang.Object)
public final PeriodList normalise()
public final PeriodList add(PeriodList periods)
periods
- a list of periods to add
public final PeriodList subtract(PeriodList subtractions)
subtractions
- a list of periods to subtract from this list
public final boolean isUtc()
public final void setUtc(boolean utc)
utc
- The utc to set.public final void setTimeZone(TimeZone timeZone)
timeZone
- the timezone for the period listpublic final TimeZone getTimeZone()
public boolean addAll(java.util.Collection arg0)
addAll
in interface java.util.Collection
addAll
in interface java.util.Set
public void clear()
clear
in interface java.util.Collection
clear
in interface java.util.Set
public boolean contains(java.lang.Object o)
contains
in interface java.util.Collection
contains
in interface java.util.Set
public boolean containsAll(java.util.Collection arg0)
containsAll
in interface java.util.Collection
containsAll
in interface java.util.Set
public boolean isEmpty()
isEmpty
in interface java.util.Collection
isEmpty
in interface java.util.Set
public java.util.Iterator iterator()
iterator
in interface java.lang.Iterable
iterator
in interface java.util.Collection
iterator
in interface java.util.Set
public boolean remove(java.lang.Object o)
remove
in interface java.util.Collection
remove
in interface java.util.Set
public boolean removeAll(java.util.Collection arg0)
removeAll
in interface java.util.Collection
removeAll
in interface java.util.Set
public boolean retainAll(java.util.Collection arg0)
retainAll
in interface java.util.Collection
retainAll
in interface java.util.Set
public int size()
size
in interface java.util.Collection
size
in interface java.util.Set
public java.lang.Object[] toArray()
toArray
in interface java.util.Collection
toArray
in interface java.util.Set
public java.lang.Object[] toArray(java.lang.Object[] arg0)
toArray
in interface java.util.Collection
toArray
in interface java.util.Set
public boolean equals(java.lang.Object obj)
equals
in interface java.util.Collection
equals
in interface java.util.Set
equals
in class java.lang.Object
public int hashCode()
hashCode
in interface java.util.Collection
hashCode
in interface java.util.Set
hashCode
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |