Class VTimeZone
java.lang.Object
net.fortuna.ical4j.model.Component
net.fortuna.ical4j.model.component.CalendarComponent
net.fortuna.ical4j.model.component.VTimeZone
- All Implemented Interfaces:
Serializable,ComponentContainer<Observance>,FluentComponent,PropertyContainer
$Id$ [Apr 5, 2004]
Defines an iCalendar VTIMEZONE component.
4.6.5 Time Zone Component
Component Name: VTIMEZONE
Purpose: Provide a grouping of component properties that defines a
time zone.
Formal Definition: A "VTIMEZONE" calendar component is defined by the
following notation:
timezonec = "BEGIN" ":" "VTIMEZONE" CRLF
2*(
; 'tzid' is required, but MUST NOT occur more
; than once
tzid /
; 'last-mod' and 'tzurl' are optional,
but MUST NOT occur more than once
last-mod / tzurl /
; one of 'standardc' or 'daylightc' MUST occur
..; and each MAY occur more than once.
standardc / daylightc /
; the following is optional,
; and MAY occur more than once
x-prop
)
"END" ":" "VTIMEZONE" CRLF
standardc = "BEGIN" ":" "STANDARD" CRLF
tzprop
"END" ":" "STANDARD" CRLF
daylightc = "BEGIN" ":" "DAYLIGHT" CRLF
tzprop
"END" ":" "DAYLIGHT" CRLF
tzprop = 3*(
; the following are each REQUIRED,
; but MUST NOT occur more than once
dtstart / tzoffsetto / tzoffsetfrom /
; the following are optional,
; and MAY occur more than once
comment / rdate / rrule / tzname / x-prop
)
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class net.fortuna.ical4j.model.component.CalendarComponent
EMPTY_VALIDATORFields inherited from class net.fortuna.ical4j.model.Component
AVAILABLE, BEGIN, components, END, EXPERIMENTAL_PREFIX, PARTICIPANT, VALARM, VAVAILABILITY, VEVENT, VFREEBUSY, VJOURNAL, VLOCATION, VRESOURCE, VTIMEZONE, VTODO, VVENUE -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.VTimeZone(ComponentList<Observance> observances) Constructs a new vtimezone component with no properties and the specified list of type components.VTimeZone(PropertyList properties) Constructs a new instance containing the specified properties.VTimeZone(PropertyList properties, ComponentList<Observance> observances) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionbooleanfinal ObservancegetApplicableObservance(Date date) Returns the latest applicable timezone observance for the specified date.final LastModifiedfinal ComponentList<Observance>final TzIdfinal TzUrlprotected ValidatorgetValidator(Method method) inthashCode()validate(boolean recurse) Perform validation on a component.Methods inherited from class net.fortuna.ical4j.model.component.CalendarComponent
validate, validateAdd, validateCancel, validateCounter, validateDeclineCounter, validatePublish, validateRefresh, validateReply, validateRequestMethods inherited from class net.fortuna.ical4j.model.Component
calculateRecurrenceSet, copy, getFluentTarget, getName, getProperties, getRequiredProperty, toString, validate, validatePropertiesMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.fortuna.ical4j.model.ComponentContainer
getComponent, getComponentsMethods inherited from interface net.fortuna.ical4j.model.FluentComponent
withPropertyMethods inherited from interface net.fortuna.ical4j.model.PropertyContainer
getProperties, getProperty
-
Constructor Details
-
VTimeZone
public VTimeZone()Default constructor. -
VTimeZone
Constructs a new instance containing the specified properties.- Parameters:
properties- a list of properties
-
VTimeZone
Constructs a new vtimezone component with no properties and the specified list of type components.- Parameters:
observances- a list of type components
-
VTimeZone
Constructor.- Parameters:
properties- a list of propertiesobservances- a list of timezone types
-
-
Method Details
-
validate
Perform validation on a component.- Specified by:
validatein classComponent- Parameters:
recurse- indicates whether to validate the component's properties- Throws:
ValidationException- where the component is not in a valid state
-
getValidator
- Specified by:
getValidatorin classCalendarComponent- Parameters:
method- a method to validate on- Returns:
- a validator for the specified method or null if the method is not supported
-
getObservances
- Returns:
- Returns the types.
-
getComponents
- Specified by:
getComponentsin interfaceComponentContainer<Observance>
-
getApplicableObservance
Returns the latest applicable timezone observance for the specified date.- Parameters:
date- the latest possible date for a timezone observance onset- Returns:
- the latest applicable timezone observance for the specified date or null if there are no applicable observances
-
getTimeZoneId
- Returns:
- the mandatory timezone identifier property
-
getLastModified
- Returns:
- the optional last-modified property
-
getTimeZoneUrl
- Returns:
- the optional timezone url property
-
equals
-
hashCode
public int hashCode()
-