|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.fortuna.ical4j.model.Component
public abstract class Component
$Id: Component.java,v 1.36 2011/02/20 03:12:32 fortuna Exp $ [Apr 5, 2004] Defines an iCalendar component. Subclasses of this class provide additional validation and typed values for specific iCalendar components.
Field Summary | |
---|---|
static java.lang.String |
AVAILABLE
Component token. |
static java.lang.String |
BEGIN
Component start token. |
static java.lang.String |
END
Component end token. |
static java.lang.String |
EXPERIMENTAL_PREFIX
Prefix for non-standard components. |
static java.lang.String |
VALARM
Component token. |
static java.lang.String |
VAVAILABILITY
Component token. |
static java.lang.String |
VEVENT
Component token. |
static java.lang.String |
VFREEBUSY
Component token. |
static java.lang.String |
VJOURNAL
Component token. |
static java.lang.String |
VTIMEZONE
Component token. |
static java.lang.String |
VTODO
Component token. |
static java.lang.String |
VVENUE
Component token. |
Constructor Summary | |
---|---|
protected |
Component(java.lang.String s)
Constructs a new component containing no properties. |
protected |
Component(java.lang.String s,
PropertyList p)
Constructor made protected to enforce the use of ComponentFactory for component instantiation. |
Method Summary | |
---|---|
PeriodList |
calculateRecurrenceSet(Period period)
Calculates the recurrence set for this component using the specified period. |
Component |
copy()
Create a (deep) copy of this component. |
boolean |
equals(java.lang.Object arg0)
|
java.lang.String |
getName()
|
PropertyList |
getProperties()
|
PropertyList |
getProperties(java.lang.String name)
Convenience method for retrieving a list of named properties. |
Property |
getProperty(java.lang.String name)
Convenience method for retrieving a named property. |
int |
hashCode()
|
java.lang.String |
toString()
|
void |
validate()
Perform validation on a component and its properties. |
abstract void |
validate(boolean recurse)
Perform validation on a component. |
protected void |
validateProperties()
Invoke validation on the component properties in its current state. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String BEGIN
public static final java.lang.String END
public static final java.lang.String VEVENT
public static final java.lang.String VTODO
public static final java.lang.String VJOURNAL
public static final java.lang.String VFREEBUSY
public static final java.lang.String VTIMEZONE
public static final java.lang.String VALARM
public static final java.lang.String VAVAILABILITY
public static final java.lang.String VVENUE
public static final java.lang.String AVAILABLE
public static final java.lang.String EXPERIMENTAL_PREFIX
Constructor Detail |
---|
protected Component(java.lang.String s)
s
- a component nameprotected Component(java.lang.String s, PropertyList p)
ComponentFactory
for component instantiation.
s
- component namep
- a list of propertiesMethod Detail |
---|
public java.lang.String toString()
toString
in class java.lang.Object
public final java.lang.String getName()
public final PropertyList getProperties()
public final PropertyList getProperties(java.lang.String name)
name
- name of properties to retrieve
public final Property getProperty(java.lang.String name)
name
- name of the property to retrieve
public final void validate() throws ValidationException
ValidationException
- where the component is not in a valid statepublic abstract void validate(boolean recurse) throws ValidationException
recurse
- indicates whether to validate the component's properties
ValidationException
- where the component is not in a valid stateprotected final void validateProperties() throws ValidationException
ValidationException
- where any of the component properties is not in a valid statepublic boolean equals(java.lang.Object arg0)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public Component copy() throws java.text.ParseException, java.io.IOException, java.net.URISyntaxException
java.io.IOException
- where an error occurs reading the component data
java.text.ParseException
- where parsing component data fails
java.net.URISyntaxException
- where component data contains an invalid URIpublic final PeriodList calculateRecurrenceSet(Period period)
If an explicit DURATION is not specified, the effective duration of each returned period is derived from the DTSTART and DTEND or DUE properties. If the component has no DURATION, DTEND or DUE, the effective duration is set to PT0S
period
- a range to calculate recurrences for
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |