caldav

package
v0.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2020 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const DateFormat = `20060102T150405`

DateFormat ist the caldav date format

Variables

This section is empty.

Functions

func ParseEvents

func ParseEvents(config *Config, events []*Event) (caldavevents string)

ParseEvents parses an array of caldav events and gives them back as string

func ParseTodos

func ParseTodos(config *Config, todos []*Todo) (caldavtodos string)

ParseTodos returns a caldav vcalendar string with todos

Types

type Alarm

type Alarm struct {
	Time        timeutil.TimeStamp
	Description string
}

Alarm holds infos about an alarm from a caldav event

type Config

type Config struct {
	Name   string
	ProdID string
}

Config is the caldav calendar config

type Event

type Event struct {
	Summary     string
	Description string
	UID         string
	Alarms      []Alarm

	Timestamp timeutil.TimeStamp
	Start     timeutil.TimeStamp
	End       timeutil.TimeStamp
}

Event holds a single caldav event

type Todo

type Todo struct {
	// Required
	Timestamp timeutil.TimeStamp
	UID       string

	// Optional
	Summary      string
	Description  string
	Completed    timeutil.TimeStamp
	Organizer    *user.User
	Priority     int64 // 0-9, 1 is highest
	RelatedToUID string

	Start    timeutil.TimeStamp
	End      timeutil.TimeStamp
	DueDate  timeutil.TimeStamp
	Duration time.Duration

	Created timeutil.TimeStamp
	Updated timeutil.TimeStamp // last-mod
}

Todo holds a single VTODO

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL