Package org.exoplatform.caldav.storage
Class CaldavConnectorStorage
java.lang.Object
org.exoplatform.caldav.storage.CaldavConnectorStorage
-
Constructor Summary
ConstructorsConstructorDescriptionCaldavConnectorStorage(org.exoplatform.commons.api.settings.SettingService settingService) -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateCaldavSetting(org.exoplatform.caldav.model.CaldavUserSetting caldavUserSetting, long userIdentityId) Stores the credentials of the connected CalDAV account of a user and, when the account was connected through a declared server registration, the identifier of that registration.voiddeleteCaldavSetting(long userIdentityId) Deletes every stored CalDAV setting of a user: credentials and mirror calendar href alike, so a later reconnection starts from a clean state and never silently reuses the mirror of a previous account.org.exoplatform.caldav.model.CaldavUserSettinggetCaldavSetting(long userIdentityId) Retrieves the CalDAV settings of a user: the credentials of the connected account and, when one has been established, the href of the mirror calendar.voidsaveMirrorCalendarHref(String mirrorCalendarHref, long userIdentityId) Saves the href of the mirror calendar of a user, the remote collection every meeting pushed by eXo is written to.
-
Constructor Details
-
CaldavConnectorStorage
public CaldavConnectorStorage(org.exoplatform.commons.api.settings.SettingService settingService)
-
-
Method Details
-
createCaldavSetting
public void createCaldavSetting(org.exoplatform.caldav.model.CaldavUserSetting caldavUserSetting, long userIdentityId) Stores the credentials of the connected CalDAV account of a user and, when the account was connected through a declared server registration, the identifier of that registration. A connection made outside any registration (the legacy single-server deployment) removes a previously stored reference rather than leaving a stale one pointing the new account at the old server.- Parameters:
caldavUserSetting- setting holding the credentials and, optionally, the server registration identifieruserIdentityId- technical identity identifier of the user
-
saveMirrorCalendarHref
Saves the href of the mirror calendar of a user, the remote collection every meeting pushed by eXo is written to. The href is stored beside the other settings of the CalDAV account of that user, so disconnecting the account removes it with the rest.- Parameters:
mirrorCalendarHref- href of the mirror calendar collectionuserIdentityId- technical identity identifier of the user
-
getCaldavSetting
public org.exoplatform.caldav.model.CaldavUserSetting getCaldavSetting(long userIdentityId) Retrieves the CalDAV settings of a user: the credentials of the connected account and, when one has been established, the href of the mirror calendar.- Parameters:
userIdentityId- technical identity identifier of the user- Returns:
- the
CaldavUserSettingof that user, never null
-
deleteCaldavSetting
public void deleteCaldavSetting(long userIdentityId) Deletes every stored CalDAV setting of a user: credentials and mirror calendar href alike, so a later reconnection starts from a clean state and never silently reuses the mirror of a previous account.- Parameters:
userIdentityId- technical identity identifier of the user
-