Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CalDAVStorage ¶
type CalDAVStorage struct {
// contains filtered or unexported fields
}
func NewCalDAVStorage ¶
func NewCalDAVStorage(serverURL, username, password, calendarPath string) (*CalDAVStorage, error)
NewCalDAVStorage creates a new CalDAVStorage with the given server URL
func NewCalDAVStorageFromConfig ¶
func NewCalDAVStorageFromConfig(config WebdavConfig) (*CalDAVStorage, error)
func NewCalDAVStorageFromURL ¶
func NewCalDAVStorageFromURL(fullURL string) (*CalDAVStorage, error)
func (*CalDAVStorage) DeleteEvent ¶
func (s *CalDAVStorage) DeleteEvent(uid string) error
DeleteEvent deletes a calendar event from CalDAV by its UID
func (*CalDAVStorage) GetEvent ¶
func (s *CalDAVStorage) GetEvent(uid string) (*icalParser.Event, error)
GetEvent retrieves a calendar event from CalDAV by its UID
func (*CalDAVStorage) ListEvents ¶
func (s *CalDAVStorage) ListEvents() ([]*icalParser.Event, error)
ListEvents lists all events from the CalDAV calendar
func (*CalDAVStorage) StoreEvent ¶
func (s *CalDAVStorage) StoreEvent(event *icalParser.Event) error
StoreEvent stores a calendar event via CalDAV
type MemoryStorage ¶
type MemoryStorage struct {
// contains filtered or unexported fields
}
func NewMemoryStorage ¶
func NewMemoryStorage() *MemoryStorage
func (*MemoryStorage) DeleteEvent ¶
func (m *MemoryStorage) DeleteEvent(uid string) error
func (*MemoryStorage) GetEventCount ¶
func (m *MemoryStorage) GetEventCount() int
func (*MemoryStorage) ListEvents ¶
func (m *MemoryStorage) ListEvents() ([]*ical.Event, error)
func (*MemoryStorage) StoreEvent ¶
func (m *MemoryStorage) StoreEvent(event *ical.Event) error
type Storage ¶
type Storage interface {
// StoreEvent stores a calendar event in the storage
StoreEvent(event *ical.Event) error
// GetEvent retrieves a calendar event from the storage by its UID
GetEvent(id string) (*ical.Event, error)
// ListEvents lists all events in the storage
ListEvents() ([]*ical.Event, error)
// DeleteEvent deletes a calendar event from the storage by its UID
DeleteEvent(id string) error
}
Storage defines the interface for storing calendar events
Click to show internal directories.
Click to hide internal directories.