biweekly.component
Class VTodo

java.lang.Object
  extended by biweekly.component.ICalComponent
      extended by biweekly.component.VTodo

public class VTodo
extends ICalComponent

Defines a task or assignment.

Examples:

 VTodo todo = new VTodo();
 todo.setSummary("Complete report");
 Date due = ...
 todo.setDateDue(due);
 todo.setStatus(Status.confirmed());
 

Author:
Michael Angstadt
Specification Reference:
RFC 5545 p.55-7

Field Summary
 
Fields inherited from class biweekly.component.ICalComponent
components, properties
 
Constructor Summary
VTodo()
           Creates a new to-do entry.
 
Method Summary
 void addAlarm(VAlarm alarm)
          Adds an alarm to this to-do.
 void addAttachment(Attachment attachment)
          Adds an attachment to the to-do.
 void addAttendee(Attendee attendee)
          Adds a person who is involved in the to-do.
 Attendee addAttendee(String email)
          Adds a person who is involved in the to-do.
 void addCategories(Categories categories)
          Adds a list of "tags" or "keywords" that describe the to-do.
 Categories addCategories(List<String> categories)
          Adds a list of "tags" or "keywords" that describe the to-do.
 Categories addCategories(String... categories)
          Adds a list of "tags" or "keywords" that describe the to-do.
 void addComment(Comment comment)
          Adds a comment to the to-do.
 Comment addComment(String comment)
          Adds a comment to the to-do.
 void addContact(Contact contact)
          Adds a contact to the to-do.
 Contact addContact(String contact)
          Adds a contact to the to-do.
 void addExceptionDates(ExceptionDates exceptionDates)
          Adds a list of exceptions to the recurrence rule defined in the to-do (if one is defined).
 void addExceptionRule(ExceptionRule exceptionRule)
           Adds an exception for the RecurrenceRule property.
 ExceptionRule addExceptionRule(Recurrence recur)
           Adds an exception for the RecurrenceRule property.
 void addRecurrenceDates(RecurrenceDates recurrenceDates)
          Adds a list of dates/periods that help define the recurrence rule of this to-do (if one is defined).
 void addRelatedTo(RelatedTo relatedTo)
          Adds a component that the to-do is related to.
 RelatedTo addRelatedTo(String uid)
          Adds a component that the to-do is related to.
 Resources addResources(List<String> resources)
          Adds a list of resources that are needed for the to-do.
 void addResources(Resources resources)
          Adds a list of resources that are needed for the to-do.
 Resources addResources(String... resources)
          Adds a list of resources that are needed for the to-do.
 List<VAlarm> getAlarms()
          Gets the alarms that are assigned to this to-do.
 List<Attachment> getAttachments()
          Gets any attachments that are associated with the to-do.
 List<Attendee> getAttendees()
          Gets the people who are involved in the to-do.
 List<Categories> getCategories()
          Gets a list of "tags" or "keywords" that describe the to-do.
 Classification getClassification()
          Gets the level of sensitivity of the to-do data.
 List<Comment> getComments()
          Gets the comments attached to the to-do.
 Completed getCompleted()
          Gets the date and time that the to-do was completed.
 List<Contact> getContacts()
          Gets the contacts associated with the to-do.
 Created getCreated()
          Gets the date-time that the to-do was initially created.
 DateDue getDateDue()
          Gets the date that a to-do is due by.
 DateStart getDateStart()
          Gets the date that the to-do starts.
 DateTimeStamp getDateTimeStamp()
          Gets either (a) the creation date of the iCalendar object (if the Method property is defined) or (b) the date that the to-do was last modified (the LastModified property also holds this information).
 Description getDescription()
          Gets a detailed description of the to-do.
 DurationProperty getDuration()
          Gets the duration of the to-do.
 List<ExceptionDates> getExceptionDates()
          Gets the list of exceptions to the recurrence rule defined in the to-do (if one is defined).
 List<ExceptionRule> getExceptionRules()
           Gets the exceptions for the RecurrenceRule property.
 Geo getGeo()
          Gets a set of geographical coordinates.
 LastModified getLastModified()
          Gets the date-time that the to-do was last changed.
 Location getLocation()
          Gets the physical location of the to-do.
 Organizer getOrganizer()
          Gets the organizer of the to-do.
 PercentComplete getPercentComplete()
          Gets the amount that the to-do task has been completed.
 Priority getPriority()
          Gets the priority of the to-do.
 List<RecurrenceDates> getRecurrenceDates()
          Gets the list of dates/periods that help define the recurrence rule of this to-do (if one is defined).
 RecurrenceId getRecurrenceId()
          Gets the original value of the DateStart property if the to-do is recurring and has been modified.
 RecurrenceRule getRecurrenceRule()
          Gets how often the to-do repeats.
 List<RelatedTo> getRelatedTo()
          Gets the components that the to-do is related to.
 RequestStatus getRequestStatus()
          Gets the response to a scheduling request.
 List<Resources> getResources()
          Gets the resources that are needed for the to-do.
 Sequence getSequence()
          Gets the revision number of the to-do.
 Status getStatus()
          Gets the status of the to-do.
 Summary getSummary()
          Gets the summary of the to-do.
 Uid getUid()
          Gets the unique identifier for this to-do.
 Url getUrl()
          Gets a URL to a resource that contains additional information about the to-do.
 void incrementSequence()
          Increments the revision number of the to-do.
 void setClassification(Classification classification)
          Sets the level of sensitivity of the to-do data.
 Classification setClassification(String classification)
          Sets the level of sensitivity of the to-do data.
 void setCompleted(Completed completed)
          Sets the date and time that the to-do was completed.
 Completed setCompleted(Date completed)
          Sets the date and time that the to-do was completed.
 void setCreated(Created created)
          Sets the date-time that the to-do was initially created.
 Created setCreated(Date created)
          Sets the date-time that the to-do was initially created.
 DateDue setDateDue(Date dateDue)
          Sets the date that a to-do is due by.
 void setDateDue(DateDue dateDue)
          Sets the date that a to-do is due by.
 DateStart setDateStart(Date dateStart)
          Sets the date that the to-do starts.
 void setDateStart(DateStart dateStart)
          Sets the date that the to-do starts.
 DateTimeStamp setDateTimeStamp(Date dateTimeStamp)
          Sets either (a) the creation date of the iCalendar object (if the Method property is defined) or (b) the date that the to-do was last modified (the LastModified property also holds this information).
 void setDateTimeStamp(DateTimeStamp dateTimeStamp)
          Sets either (a) the creation date of the iCalendar object (if the Method property is defined) or (b) the date that the to-do was last modified (the LastModified property also holds this information).
 void setDescription(Description description)
          Sets a detailed description of the to-do.
 Description setDescription(String description)
          Sets a detailed description of the to-do.
 DurationProperty setDuration(Duration duration)
          Sets the duration of the to-do.
 void setDuration(DurationProperty duration)
          Sets the duration of the to-do.
 void setGeo(Geo geo)
          Sets a set of geographical coordinates.
 LastModified setLastModified(Date lastModified)
          Sets the date-time that the to-do was last changed.
 void setLastModified(LastModified lastModified)
          Sets the date-time that the to-do was last changed.
 void setLocation(Location location)
          Sets the physical location of the to-do.
 Location setLocation(String location)
          Sets the physical location of the to-do.
 void setOrganizer(Organizer organizer)
          Sets the organizer of the to-do.
 Organizer setOrganizer(String email)
          Sets the organizer of the to-do.
 PercentComplete setPercentComplete(Integer percent)
          Sets the amount that the to-do task has been completed.
 void setPercentComplete(PercentComplete percentComplete)
          Sets the amount that the to-do task has been completed.
 Priority setPriority(Integer priority)
          Sets the priority of the to-do.
 void setPriority(Priority priority)
          Sets the priority of the to-do.
 RecurrenceId setRecurrenceId(Date originalStartDate)
          Sets the original value of the DateStart property if the to-do is recurring and has been modified.
 void setRecurrenceId(RecurrenceId recurrenceId)
          Sets the original value of the DateStart property if the to-do is recurring and has been modified.
 RecurrenceRule setRecurrenceRule(Recurrence recur)
          Sets how often the to-do repeats.
 void setRecurrenceRule(RecurrenceRule recurrenceRule)
          Sets how often the to-do repeats.
 void setRequestStatus(RequestStatus requestStatus)
          Sets the response to a scheduling request.
 Sequence setSequence(Integer sequence)
          Sets the revision number of the to-do.
 void setSequence(Sequence sequence)
          Sets the revision number of the to-do.
 void setStatus(Status status)
          Sets the status of the to-do.
 Summary setSummary(String summary)
          Sets the summary of the to-do.
 void setSummary(Summary summary)
          Sets the summary of the to-do.
 Uid setUid(String uid)
          Sets the unique identifier for this to-do.
 void setUid(Uid uid)
          Sets the unique identifier for this to-do.
 Url setUrl(String url)
          Sets a URL to a resource that contains additional information about the to-do.
 void setUrl(Url url)
          Sets a URL to a resource that contains additional information about the to-do.
protected  void validate(List<ICalComponent> components, List<String> warnings)
          Checks the component for data consistency problems or deviations from the spec.
 
Methods inherited from class biweekly.component.ICalComponent
addComponent, addExperimentalComponent, addExperimentalProperty, addExperimentalProperty, addProperty, checkOptionalCardinality, checkRequiredCardinality, getComponent, getComponents, getComponents, getExperimentalComponent, getExperimentalComponents, getExperimentalComponents, getExperimentalProperties, getExperimentalProperties, getExperimentalProperty, getProperties, getProperties, getProperty, removeExperimentalComponents, removeExperimentalProperty, removeProperties, setComponent, setComponent, setExperimentalComponents, setExperimentalProperty, setExperimentalProperty, setProperty, setProperty, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VTodo

public VTodo()

Creates a new to-do entry.

The following properties are auto-generated on object creation. These properties must be present in order for the to-do to be valid:

Method Detail

getUid

public Uid getUid()
Gets the unique identifier for this to-do. This component object comes populated with a UID on creation. This is a required property.

Returns:
the UID or null if not set
Specification Reference:
RFC 5545 p.117-8

setUid

public void setUid(Uid uid)
Sets the unique identifier for this to-do. This component object comes populated with a UID on creation. This is a required property.

Parameters:
uid - the UID or null to remove
Specification Reference:
RFC 5545 p.117-8

setUid

public Uid setUid(String uid)
Sets the unique identifier for this to-do. This component object comes populated with a UID on creation. This is a required property.

Parameters:
uid - the UID or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.117-8

getDateTimeStamp

public DateTimeStamp getDateTimeStamp()
Gets either (a) the creation date of the iCalendar object (if the Method property is defined) or (b) the date that the to-do was last modified (the LastModified property also holds this information). This to-do object comes populated with a DateTimeStamp property that is set to the current time. This is a required property.

Returns:
the date time stamp or null if not set
Specification Reference:
RFC 5545 p.137-8

setDateTimeStamp

public void setDateTimeStamp(DateTimeStamp dateTimeStamp)
Sets either (a) the creation date of the iCalendar object (if the Method property is defined) or (b) the date that the to-do was last modified (the LastModified property also holds this information). This to-do object comes populated with a DateTimeStamp property that is set to the current time. This is a required property.

Parameters:
dateTimeStamp - the date time stamp or null to remove
Specification Reference:
RFC 5545 p.137-8

setDateTimeStamp

public DateTimeStamp setDateTimeStamp(Date dateTimeStamp)
Sets either (a) the creation date of the iCalendar object (if the Method property is defined) or (b) the date that the to-do was last modified (the LastModified property also holds this information). This to-do object comes populated with a DateTimeStamp property that is set to the current time. This is a required property.

Parameters:
dateTimeStamp - the date time stamp or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.137-8

getClassification

public Classification getClassification()
Gets the level of sensitivity of the to-do data. If not specified, the data within the to-do should be considered "public".

Returns:
the classification level or null if not set
Specification Reference:
RFC 5545 p.82-3

setClassification

public void setClassification(Classification classification)
Sets the level of sensitivity of the to-do data. If not specified, the data within the to-do should be considered "public".

Parameters:
classification - the classification level or null to remove
Specification Reference:
RFC 5545 p.82-3

setClassification

public Classification setClassification(String classification)
Sets the level of sensitivity of the to-do data. If not specified, the data within the to-do should be considered "public".

Parameters:
classification - the classification level (e.g. "CONFIDENTIAL") or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.82-3

getCompleted

public Completed getCompleted()
Gets the date and time that the to-do was completed.

Returns:
the completion date or null if not set
Specification Reference:
RFC 5545 p.94-5

setCompleted

public void setCompleted(Completed completed)
Sets the date and time that the to-do was completed.

Parameters:
completed - the completion date or null to remove
Specification Reference:
RFC 5545 p.94-5

setCompleted

public Completed setCompleted(Date completed)
Sets the date and time that the to-do was completed.

Parameters:
completed - the completion date or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.94-5

getCreated

public Created getCreated()
Gets the date-time that the to-do was initially created.

Returns:
the creation date-time or null if not set
Specification Reference:
RFC 5545 p.136

setCreated

public void setCreated(Created created)
Sets the date-time that the to-do was initially created.

Parameters:
created - the creation date-time or null to remove
Specification Reference:
RFC 5545 p.136

setCreated

public Created setCreated(Date created)
Sets the date-time that the to-do was initially created.

Parameters:
created - the creation date-time or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.136

getDescription

public Description getDescription()
Gets a detailed description of the to-do. The description should be more detailed than the one provided by the Summary property.

Returns:
the description or null if not set
Specification Reference:
RFC 5545 p.84-5

setDescription

public void setDescription(Description description)
Sets a detailed description of the to-do. The description should be more detailed than the one provided by the Summary property.

Parameters:
description - the description or null to remove
Specification Reference:
RFC 5545 p.84-5

setDescription

public Description setDescription(String description)
Sets a detailed description of the to-do. The description should be more detailed than the one provided by the Summary property.

Parameters:
description - the description or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.84-5

getDateStart

public DateStart getDateStart()
Gets the date that the to-do starts.

Returns:
the start date or null if not set
Specification Reference:
RFC 5545 p.97-8

setDateStart

public void setDateStart(DateStart dateStart)
Sets the date that the to-do starts.

Parameters:
dateStart - the start date or null to remove
Specification Reference:
RFC 5545 p.97-8

setDateStart

public DateStart setDateStart(Date dateStart)
Sets the date that the to-do starts.

Parameters:
dateStart - the start date or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.97-8

getGeo

public Geo getGeo()
Gets a set of geographical coordinates.

Returns:
the geographical coordinates or null if not set
Specification Reference:
RFC 5545 p.85-7

setGeo

public void setGeo(Geo geo)
Sets a set of geographical coordinates.

Parameters:
geo - the geographical coordinates or null to remove
Specification Reference:
RFC 5545 p.85-7

getLastModified

public LastModified getLastModified()
Gets the date-time that the to-do was last changed.

Returns:
the last modified date or null if not set
Specification Reference:
RFC 5545 p.138

setLastModified

public void setLastModified(LastModified lastModified)
Sets the date-time that the to-do was last changed.

Parameters:
lastModified - the last modified date or null to remove
Specification Reference:
RFC 5545 p.138

setLastModified

public LastModified setLastModified(Date lastModified)
Sets the date-time that the to-do was last changed.

Parameters:
lastModified - the last modified date or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.138

getLocation

public Location getLocation()
Gets the physical location of the to-do.

Returns:
the location or null if not set
Specification Reference:
RFC 5545 p.87-8

setLocation

public void setLocation(Location location)
Sets the physical location of the to-do.

Parameters:
location - the location or null to remove
Specification Reference:
RFC 5545 p.87-8

setLocation

public Location setLocation(String location)
Sets the physical location of the to-do.

Parameters:
location - the location (e.g. "Room 101") or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.87-8

getOrganizer

public Organizer getOrganizer()
Gets the organizer of the to-do.

Returns:
the organizer or null if not set
Specification Reference:
RFC 5545 p.111-2

setOrganizer

public void setOrganizer(Organizer organizer)
Sets the organizer of the to-do.

Parameters:
organizer - the organizer or null to remove
Specification Reference:
RFC 5545 p.111-2

setOrganizer

public Organizer setOrganizer(String email)
Sets the organizer of the to-do.

Parameters:
email - the organizer's email address (e.g. "johndoe@example.com") or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.111-2

getPercentComplete

public PercentComplete getPercentComplete()
Gets the amount that the to-do task has been completed.

Returns:
the percent complete or null if not set
Specification Reference:
RFC 5545 p.88-9

setPercentComplete

public void setPercentComplete(PercentComplete percentComplete)
Sets the amount that the to-do task has been completed.

Parameters:
percentComplete - the percent complete or null to remove
Specification Reference:
RFC 5545 p.88-9

setPercentComplete

public PercentComplete setPercentComplete(Integer percent)
Sets the amount that the to-do task has been completed.

Parameters:
percent - the percent complete (e.g. "50" for 50%) or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.88-9

getPriority

public Priority getPriority()
Gets the priority of the to-do.

Returns:
the priority or null if not set
Specification Reference:
RFC 5545 p.89-90

setPriority

public void setPriority(Priority priority)
Sets the priority of the to-do.

Parameters:
priority - the priority or null to remove
Specification Reference:
RFC 5545 p.89-90

setPriority

public Priority setPriority(Integer priority)
Sets the priority of the to-do.

Parameters:
priority - the priority ("0" is undefined, "1" is the highest, "9" is the lowest) or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.89-90

getRecurrenceId

public RecurrenceId getRecurrenceId()
Gets the original value of the DateStart property if the to-do is recurring and has been modified. Used in conjunction with the Uid and Sequence properties to uniquely identify a recurrence instance.

Returns:
the recurrence ID or null if not set
Specification Reference:
RFC 5545 p.112-4

setRecurrenceId

public void setRecurrenceId(RecurrenceId recurrenceId)
Sets the original value of the DateStart property if the to-do is recurring and has been modified. Used in conjunction with the Uid and Sequence properties to uniquely identify a recurrence instance.

Parameters:
recurrenceId - the recurrence ID or null to remove
Specification Reference:
RFC 5545 p.112-4

setRecurrenceId

public RecurrenceId setRecurrenceId(Date originalStartDate)
Sets the original value of the DateStart property if the to-do is recurring and has been modified. Used in conjunction with the Uid and Sequence properties to uniquely identify a recurrence instance.

Parameters:
originalStartDate - the original start date or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.112-4

getSequence

public Sequence getSequence()
Gets the revision number of the to-do. The organizer can increment this number every time he or she makes a significant change.

Returns:
the sequence number
Specification Reference:
RFC 5545 p.138-9

setSequence

public void setSequence(Sequence sequence)
Sets the revision number of the to-do. The organizer can increment this number every time he or she makes a significant change.

Parameters:
sequence - the sequence number
Specification Reference:
RFC 5545 p.138-9

setSequence

public Sequence setSequence(Integer sequence)
Sets the revision number of the to-do. The organizer can increment this number every time he or she makes a significant change.

Parameters:
sequence - the sequence number
Returns:
the property that was created
Specification Reference:
RFC 5545 p.138-9

incrementSequence

public void incrementSequence()
Increments the revision number of the to-do. The organizer can increment this number every time he or she makes a significant change.

Specification Reference:
RFC 5545 p.138-9

getStatus

public Status getStatus()
Gets the status of the to-do.

Returns:
the status or null if not set
Specification Reference:
RFC 5545 p.92-3

setStatus

public void setStatus(Status status)
Sets the status of the to-do.

Valid to-do status codes are:

Parameters:
status - the status or null to remove
Specification Reference:
RFC 5545 p.92-3

getSummary

public Summary getSummary()
Gets the summary of the to-do.

Returns:
the summary or null if not set
Specification Reference:
RFC 5545 p.93-4

setSummary

public void setSummary(Summary summary)
Sets the summary of the to-do.

Parameters:
summary - the summary or null to remove
Specification Reference:
RFC 5545 p.93-4

setSummary

public Summary setSummary(String summary)
Sets the summary of the to-do.

Parameters:
summary - the summary or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.93-4

getUrl

public Url getUrl()
Gets a URL to a resource that contains additional information about the to-do.

Returns:
the URL or null if not set
Specification Reference:
RFC 5545 p.116-7

setUrl

public void setUrl(Url url)
Sets a URL to a resource that contains additional information about the to-do.

Parameters:
url - the URL or null to remove
Specification Reference:
RFC 5545 p.116-7

setUrl

public Url setUrl(String url)
Sets a URL to a resource that contains additional information about the to-do.

Parameters:
url - the URL (e.g. "http://example.com/resource.ics") or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.116-7

getRecurrenceRule

public RecurrenceRule getRecurrenceRule()
Gets how often the to-do repeats.

Returns:
the recurrence rule or null if not set
Specification Reference:
RFC 5545 p.122-32

setRecurrenceRule

public RecurrenceRule setRecurrenceRule(Recurrence recur)
Sets how often the to-do repeats.

Parameters:
recur - the recurrence rule or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.122-32

setRecurrenceRule

public void setRecurrenceRule(RecurrenceRule recurrenceRule)
Sets how often the to-do repeats.

Parameters:
recurrenceRule - the recurrence rule or null to remove
Specification Reference:
RFC 5545 p.122-32

getDateDue

public DateDue getDateDue()
Gets the date that a to-do is due by.

Returns:
the due date or null if not set
Specification Reference:
RFC 5545 p.96-7

setDateDue

public void setDateDue(DateDue dateDue)
Sets the date that a to-do is due by. This must NOT be set if a DurationProperty is defined.

Parameters:
dateDue - the due date or null to remove
Specification Reference:
RFC 5545 p.96-7

setDateDue

public DateDue setDateDue(Date dateDue)
Sets the date that a to-do is due by. This must NOT be set if a DurationProperty is defined.

Parameters:
dateDue - the due date or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.96-7

getDuration

public DurationProperty getDuration()
Gets the duration of the to-do.

Returns:
the duration or null if not set
Specification Reference:
RFC 5545 p.99

setDuration

public void setDuration(DurationProperty duration)
Sets the duration of the to-do. This must NOT be set if a DateDue is defined.

Parameters:
duration - the duration or null to remove
Specification Reference:
RFC 5545 p.99

setDuration

public DurationProperty setDuration(Duration duration)
Sets the duration of the to-do. This must NOT be set if a DateDue is defined.

Parameters:
duration - the duration or null to remove
Returns:
the property that was created
Specification Reference:
RFC 5545 p.99

getAttachments

public List<Attachment> getAttachments()
Gets any attachments that are associated with the to-do.

Returns:
the attachments
Specification Reference:
RFC 5545 p.80-1

addAttachment

public void addAttachment(Attachment attachment)
Adds an attachment to the to-do.

Parameters:
attachment - the attachment to add
Specification Reference:
RFC 5545 p.80-1

getAttendees

public List<Attendee> getAttendees()
Gets the people who are involved in the to-do.

Returns:
the attendees
Specification Reference:
RFC 5545 p.107-9

addAttendee

public void addAttendee(Attendee attendee)
Adds a person who is involved in the to-do.

Parameters:
attendee - the attendee
Specification Reference:
RFC 5545 p.107-9

addAttendee

public Attendee addAttendee(String email)
Adds a person who is involved in the to-do.

Parameters:
email - the attendee's email address
Returns:
the property that was created
Specification Reference:
RFC 5545 p.107-9

getCategories

public List<Categories> getCategories()
Gets a list of "tags" or "keywords" that describe the to-do.

Returns:
the categories
Specification Reference:
RFC 5545 p.81-2

addCategories

public void addCategories(Categories categories)
Adds a list of "tags" or "keywords" that describe the to-do. Note that a single property can hold multiple keywords.

Parameters:
categories - the categories to add
Specification Reference:
RFC 5545 p.81-2

addCategories

public Categories addCategories(String... categories)
Adds a list of "tags" or "keywords" that describe the to-do.

Parameters:
categories - the categories to add
Returns:
the property that was created
Specification Reference:
RFC 5545 p.81-2

addCategories

public Categories addCategories(List<String> categories)
Adds a list of "tags" or "keywords" that describe the to-do.

Parameters:
categories - the categories to add
Returns:
the property that was created
Specification Reference:
RFC 5545 p.81-2

getComments

public List<Comment> getComments()
Gets the comments attached to the to-do.

Returns:
the comments
Specification Reference:
RFC 5545 p.83-4

addComment

public void addComment(Comment comment)
Adds a comment to the to-do.

Parameters:
comment - the comment to add
Specification Reference:
RFC 5545 p.83-4

addComment

public Comment addComment(String comment)
Adds a comment to the to-do.

Parameters:
comment - the comment to add
Returns:
the property that was created
Specification Reference:
RFC 5545 p.83-4

getContacts

public List<Contact> getContacts()
Gets the contacts associated with the to-do.

Returns:
the contacts
Specification Reference:
RFC 5545 p.109-11

addContact

public void addContact(Contact contact)
Adds a contact to the to-do.

Parameters:
contact - the contact
Specification Reference:
RFC 5545 p.109-11

addContact

public Contact addContact(String contact)
Adds a contact to the to-do.

Parameters:
contact - the contact (e.g. "ACME Co - (123) 555-1234")
Returns:
the property that was created
Specification Reference:
RFC 5545 p.109-11

getExceptionDates

public List<ExceptionDates> getExceptionDates()
Gets the list of exceptions to the recurrence rule defined in the to-do (if one is defined).

Returns:
the list of exceptions
Specification Reference:
RFC 5545 p.118-20

addExceptionDates

public void addExceptionDates(ExceptionDates exceptionDates)
Adds a list of exceptions to the recurrence rule defined in the to-do (if one is defined). Note that this property can contain multiple dates.

Parameters:
exceptionDates - the list of exceptions
Specification Reference:
RFC 5545 p.118-20

getRequestStatus

public RequestStatus getRequestStatus()
Gets the response to a scheduling request.

Returns:
the response
Specification Reference:
RFC 5545 p.141-3

setRequestStatus

public void setRequestStatus(RequestStatus requestStatus)
Sets the response to a scheduling request.

Parameters:
requestStatus - the response
Specification Reference:
RFC 5545 p.141-3

getRelatedTo

public List<RelatedTo> getRelatedTo()
Gets the components that the to-do is related to.

Returns:
the relationships
Specification Reference:
RFC 5545 p.115-6

addRelatedTo

public void addRelatedTo(RelatedTo relatedTo)
Adds a component that the to-do is related to.

Parameters:
relatedTo - the relationship
Specification Reference:
RFC 5545 p.115-6

addRelatedTo

public RelatedTo addRelatedTo(String uid)
Adds a component that the to-do is related to.

Parameters:
uid - the UID of the other component
Returns:
the property that was created
Specification Reference:
RFC 5545 p.115-6

getResources

public List<Resources> getResources()
Gets the resources that are needed for the to-do.

Returns:
the resources
Specification Reference:
RFC 5545 p.91

addResources

public void addResources(Resources resources)
Adds a list of resources that are needed for the to-do. Note that a single property can hold multiple resources.

Parameters:
resources - the resources to add
Specification Reference:
RFC 5545 p.91

addResources

public Resources addResources(String... resources)
Adds a list of resources that are needed for the to-do.

Parameters:
resources - the resources to add (e.g. "easel", "projector")
Returns:
the property that was created
Specification Reference:
RFC 5545 p.91

addResources

public Resources addResources(List<String> resources)
Adds a list of resources that are needed for the to-do.

Parameters:
resources - the resources to add (e.g. "easel", "projector")
Returns:
the property that was created
Specification Reference:
RFC 5545 p.91

getRecurrenceDates

public List<RecurrenceDates> getRecurrenceDates()
Gets the list of dates/periods that help define the recurrence rule of this to-do (if one is defined).

Returns:
the recurrence dates
Specification Reference:
RFC 5545 p.120-2

addRecurrenceDates

public void addRecurrenceDates(RecurrenceDates recurrenceDates)
Adds a list of dates/periods that help define the recurrence rule of this to-do (if one is defined).

Parameters:
recurrenceDates - the recurrence dates
Specification Reference:
RFC 5545 p.120-2

getAlarms

public List<VAlarm> getAlarms()
Gets the alarms that are assigned to this to-do.

Returns:
the alarms
Specification Reference:
RFC 5545 p.71-6

addAlarm

public void addAlarm(VAlarm alarm)
Adds an alarm to this to-do.

Parameters:
alarm - the alarm
Specification Reference:
RFC 5545 p.71-6

getExceptionRules

public List<ExceptionRule> getExceptionRules()

Gets the exceptions for the RecurrenceRule property.

Note that this property has been removed from the latest version of the iCal specification. Its use should be avoided.

Returns:
the exception rules
Specification Reference:
RFC 2445 p.114-15

addExceptionRule

public ExceptionRule addExceptionRule(Recurrence recur)

Adds an exception for the RecurrenceRule property.

Note that this property has been removed from the latest version of the iCal specification. Its use should be avoided.

Parameters:
recur - the exception rule to add
Returns:
the property that was created
Specification Reference:
RFC 2445 p.114-15

addExceptionRule

public void addExceptionRule(ExceptionRule exceptionRule)

Adds an exception for the RecurrenceRule property.

Note that this property has been removed from the latest version of the iCal specification. Its use should be avoided.

Parameters:
exceptionRule - the exception rule to add
Specification Reference:
RFC 2445 p.114-15

validate

protected void validate(List<ICalComponent> components,
                        List<String> warnings)
Description copied from class: ICalComponent
Checks the component for data consistency problems or deviations from the spec. Meant to be overridden by child classes.

Overrides:
validate in class ICalComponent
Parameters:
components - the hierarchy of components that the component belongs to
warnings - the list to add the warnings to


Copyright © 2013 Michael Angstadt. All Rights Reserved.