diff options
Diffstat (limited to 'pim/lib/cal/backend.go')
| -rw-r--r-- | pim/lib/cal/backend.go | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/pim/lib/cal/backend.go b/pim/lib/cal/backend.go index 6dcacc2..6ed488c 100644 --- a/pim/lib/cal/backend.go +++ b/pim/lib/cal/backend.go @@ -39,3 +39,26 @@ type Backend interface { type Describer interface { Describe() string } + +// Identity is implemented by a backend that knows whose calendar this +// is. In iTIP your identity is the mailto: in your own ATTENDEE line -- +// there is no separate field for it -- so without this nothing can tell +// which of an event's attendees is you. Aliases are listed because you +// may be invited at one address and reply from another. +type Identity interface { + Me() []string +} + +// RSVPer is implemented by a backend that can answer an invitation. +// +// Accepting is two writes: update your own copy, and tell the organiser. +// A CalDAV server advertising calendar-auto-schedule does both from one +// PUT. A backend that cannot do both should not implement this at all, +// so that writing to partstat fails honestly rather than doing half of +// it and looking like it worked. +// +// recurID is the zero time to answer a whole series, or the start of +// one occurrence to answer only that. +type RSVPer interface { + RSVP(uid string, recurID time.Time, partstat string) error +} |
