### Class

# EDataCal CalBackendSync

#### Description [src]

    class EDataCal.CalBackendSync : EDataCal.CalBackend
      implements ECal.TimezoneCache {
      /* No available fields */
    }

Contains only private data that should be read and manipulated using the functions below.

#### Hierarchy

#### Ancestors

- ECalBackend
- EBackend
- GObject

#### Descendants

- ECalMetaBackend

#### Implements

- ETimezoneCache

#### Instance methods

###### e_cal_backend_sync_add_timezone

Calls the add_timezone_sync method on the given backend.

###### e_cal_backend_sync_create_objects

Calls the create_objects_sync method on the given backend.

since: 3.6

###### e_cal_backend_sync_discard_alarm

Calls the discard_alarm_sync method on the given backend.

###### e_cal_backend_sync_get_attachment_uris

Calls the get_attachment_uris_sync method on the given backend.

since: 3.2

###### e_cal_backend_sync_get_free_busy

Calls the get_free_busy_sync method on the given backend.

###### e_cal_backend_sync_get_object

Calls the get_object_sync method on the given backend.

###### e_cal_backend_sync_get_object_list

Calls the get_object_list_sync method on the given backend.

###### e_cal_backend_sync_get_timezone

Calls the get_timezone_sync method on the given backend. This method is not mandatory on the backend, because here is used internal_get_timezone call to fetch timezone from it and that is transformed to a string. In other words, any object deriving from ECalBackendSync can implement only internal_get_timezone and can skip implementation of get_timezone_sync completely.

###### e_cal_backend_sync_modify_objects

Calls the modify_objects_sync method on the given backend.

since: 3.6

###### e_cal_backend_sync_open

Calls the open_sync method on the given backend.

###### e_cal_backend_sync_receive_objects

Calls the receive_objects_sync method on the given backend.

###### e_cal_backend_sync_refresh

Calls the refresh_sync method on the given backend.

since: 2.30

###### e_cal_backend_sync_remove_objects

Calls the remove_objects_sync method on the given backend.

since: 3.6

###### e_cal_backend_sync_send_objects

Calls the send_objects_sync method on the given backend.

##### Methods inherited from ECalBackend (70)

Please see ECalBackend for a full list of methods.

##### Methods inherited from EBackend (21)

###### e_backend_credentials_required

Asynchronously calls the `e_backend_credentials_required_sync()` on the `backend`, to inform clients that credentials are required.

###### e_backend_credentials_required_finish

Finishes the operation started with e_backend_credentials_required().

###### e_backend_credentials_required_sync

Synchronously lets the clients know that the backned requires credentials to be properly opened. It’s a proxy function for e_source_invoke_credentials_required_sync(), where can be found more information about actual parameters meaning.

###### e_backend_ensure_online_state_updated

Makes sure that the “online” property is updated, that is, if there is any destination reachability test pending, it’ll be done immediately and the only state will be updated as well.

###### e_backend_ensure_source_status_connected

Makes sure that the associated ESource::connection-status is connected. This is useful in cases when the backend can connect to the destination without invoking `EBackendClass`.authenticate_sync(), possibly through e_backend_schedule_authenticate().

###### e_backend_get_destination_address

Provides destination server host name and port to which the backend connects. This is used to determine required connection point for e_backend_is_destination_reachable(). The `host` is a newly allocated string, which will be freed with g_free(). When `backend` sets both `host` and `port`, then it should return `TRUE`, indicating it’s a remote backend. Default implementation returns `FALSE`, which is treated like the backend is local, no checking for server reachability is possible.

###### e_backend_get_network_monitor

Returns a `GNetworkMonitor` used to check whether the backend can access the remote server. The instance is owned by the `backend`.

###### e_backend_get_online

Returns the online state of `backend`: `TRUE` if `backend` is online, `FALSE` if offline.

###### e_backend_get_source

Returns the `ESource` to which `backend` is paired.

###### e_backend_get_user_prompter

Gets an instance of `EUserPrompter`, associated with this `backend`.

###### e_backend_is_destination_reachable

Checks whether the `backend`‘s destination server, as returned by e_backend_get_destination_address(), is reachable. If the `e_backend_get_destination_address()` returns `FALSE`, this function returns `TRUE`, meaning the destination is always reachable. This uses `GNetworkMonitor`‘s `g_network_monitor_can_reach()` for reachability tests.

###### e_backend_prepare_shutdown

Let’s the `backend` know that it’ll be shut down shortly, no client connects to it anymore. The `backend` can free any resources which reference it, for example the opened views.

###### e_backend_ref_connectable

Returns the socket endpoint for the network service to which `backend` is a client, or `NULL` if `backend` does not use network sockets.

###### e_backend_ref_main_context

Returns the `GMainContext` on which event sources for `backend` are to be attached.

###### e_backend_schedule_authenticate

Schedules a new authenticate session, cancelling any previously run. This is usually done automatically, when an ‘authenticate’ signal is received for the associated `ESource`. With `NULL` `credentials` an attempt without it is run.

###### e_backend_schedule_credentials_required

Asynchronously invokes e_backend_credentials_required(), but installs its own callback which only prints a runtime warning on the console when the call fails. The `who_calls` is a prefix of the console message. This is useful when the caller just wants to start the operation without having actual place where to show the operation result.

###### e_backend_set_connectable

Sets the socket endpoint for the network service to which `backend` is a client. This can be `NULL` if `backend` does not use network sockets.

###### e_backend_set_online

Sets the online state of `backend`: `TRUE` if `backend` is online, `FALSE` if offline.

###### e_backend_trust_prompt

Initiates a user trust prompt with given `parameters`.

###### e_backend_trust_prompt_finish

Finishes the operation started with e_backend_trust_prompt(). If an error occurred, the function will set `error` and return `E_TRUST_PROMPT_RESPONSE_UNKNOWN`.

###### e_backend_trust_prompt_sync

Asks a user a trust prompt with given `parameters`, and returns what user responded. This blocks until the response is delivered.

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

##### Methods inherited from ETimezoneCache (3)

###### e_timezone_cache_add_timezone

Adds a copy of `zone` to `cache` and emits an `ETimezoneCache::timezone-added` signal. The `cache` will use the TZID string returned by `i_cal_timezone_get_tzid()` as the lookup key, which can be passed to `e_timezone_cache_get_timezone()` to obtain `zone` again.

###### e_timezone_cache_get_timezone

Obtains an `ICalTimezone` by its TZID string. If no match is found, the function returns `NULL`. The returned `ICalTimezone` is owned by the `cache` and should not be modified or freed.

###### e_timezone_cache_list_timezones

Returns a list of `ICalTimezone` instances that were explicitly added to the `cache` through e_timezone_cache_add_timezone(). In particular, any built-in time zone data that `e_timezone_cache_get_timezone()` may use to match a TZID string is excluded from the returned list.

#### Properties

##### Properties inherited from ECalBackend (5)

###### EDataCal.CalBackend:cache-dir

The backend’s cache directory.

###### EDataCal.CalBackend:kind

The kind of iCalendar components this backend manages.

###### EDataCal.CalBackend:proxy-resolver

The proxy resolver for this backend.

###### EDataCal.CalBackend:registry

Data source registry.

###### EDataCal.CalBackend:writable

Whether the backend will accept changes.

##### Properties inherited from EBackend (5)

###### EBackend.Backend:connectable

Socket endpoint of a network service.

###### EBackend.Backend:main-context

The main loop context on which to attach event sources.

###### EBackend.Backend:online

Whether the backend is online.

###### EBackend.Backend:source

The data source being acted upon.

###### EBackend.Backend:user-prompter

User prompter instance.

#### Signals

##### Signals inherited from ECalBackend (2)

###### ECalBackend::closed

Emitted when a client destroys its `ECalClient` for `backend`.

since: 3.10

###### ECalBackend::shutdown

Emitted when the last client destroys its `ECalClient` for `backend`. This signals the `backend` to begin final cleanup tasks such as synchronizing data to permanent storage.

since: 3.10

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

##### Signals inherited from ETimezoneCache (1)

###### ETimezoneCache::timezone-added

Emitted when a new #icaltimezone is added to `cache`.

#### Class structure

    struct EDataCalCalBackendSyncClass {
      void (* open_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        GError** error
      );
      void (* refresh_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        GError** error
      );
      void (* get_object_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* uid,
        const gchar* rid,
        gchar** calobj,
        GError** error
      );
      void (* get_object_list_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* sexp,
        GSList** calobjs,
        GError** error
      );
      void (* get_free_busy_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const GSList* users,
        time_t start,
        time_t end,
        GSList** freebusyobjs,
        GError** error
      );
      void (* create_objects_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const GSList* calobjs,
        ECalOperationFlags opflags,
        GSList** uids,
        GSList** new_components,
        GError** error
      );
      void (* modify_objects_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const GSList* calobjs,
        ECalObjModType mod,
        ECalOperationFlags opflags,
        GSList** old_components,
        GSList** new_components,
        GError** error
      );
      void (* remove_objects_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const GSList* ids,
        ECalObjModType mod,
        ECalOperationFlags opflags,
        GSList** old_components,
        GSList** new_components,
        GError** error
      );
      void (* receive_objects_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* calobj,
        ECalOperationFlags opflags,
        GError** error
      );
      void (* send_objects_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* calobj,
        ECalOperationFlags opflags,
        GSList** users,
        gchar** modified_calobj,
        GError** error
      );
      void (* get_attachment_uris_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* uid,
        const gchar* rid,
        GSList** attachments,
        GError** error
      );
      void (* discard_alarm_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* uid,
        const gchar* rid,
        const gchar* auid,
        ECalOperationFlags opflags,
        GError** error
      );
      void (* get_timezone_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* tzid,
        gchar** tzobject,
        GError** error
      );
      void (* add_timezone_sync) (
        ECalBackendSync* backend,
        EDataCal* cal,
        GCancellable* cancellable,
        const gchar* tzobject,
        GError** error
      );
      gpointer reserved_padding;

    }

Base class structure for the `ECalBackendSync` class.

###### Class members

`open_sync: void (* open_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, GError** error )`

  Open the calendar.

`refresh_sync: void (* refresh_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, GError** error )`

  Refresh the calendar.

`get_object_sync: void (* get_object_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* uid, const gchar* rid, gchar** calobj, GError** error )`

  Get single object.

`get_object_list_sync: void (* get_object_list_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* sexp, GSList** calobjs, GError** error )`

  Get multiple objects at once.

`get_free_busy_sync: void (* get_free_busy_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const GSList* users, time_t start, time_t end, GSList** freebusyobjs, GError** error )`

  Get Free/Busy objects.

`create_objects_sync: void (* create_objects_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const GSList* calobjs, ECalOperationFlags opflags, GSList** uids, GSList** new_components, GError** error )`

  Create objects.

`modify_objects_sync: void (* modify_objects_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const GSList* calobjs, ECalObjModType mod, ECalOperationFlags opflags, GSList** old_components, GSList** new_components, GError** error )`

  Modify objects.

`remove_objects_sync: void (* remove_objects_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const GSList* ids, ECalObjModType mod, ECalOperationFlags opflags, GSList** old_components, GSList** new_components, GError** error )`

  Remove objects.

`receive_objects_sync: void (* receive_objects_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* calobj, ECalOperationFlags opflags, GError** error )`

  Receive objects.

`send_objects_sync: void (* send_objects_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* calobj, ECalOperationFlags opflags, GSList** users, gchar** modified_calobj, GError** error )`

  Send objects.

`get_attachment_uris_sync: void (* get_attachment_uris_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* uid, const gchar* rid, GSList** attachments, GError** error )`

  Get attachments uris for given object.

`discard_alarm_sync: void (* discard_alarm_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* uid, const gchar* rid, const gchar* auid, ECalOperationFlags opflags, GError** error )`

  Discard alarm.

`get_timezone_sync: void (* get_timezone_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* tzid, gchar** tzobject, GError** error )`

  Get specified timezone.

`add_timezone_sync: void (* add_timezone_sync) ( ECalBackendSync* backend, EDataCal* cal, GCancellable* cancellable, const gchar* tzobject, GError** error )`

  Add specified timezone.

`reserved_padding: gpointer`

  No description available.

#### Virtual methods

###### EDataCal.CalBackendSyncClass.add_timezone_sync

Add specified timezone.

###### EDataCal.CalBackendSyncClass.create_objects_sync

Create objects.

###### EDataCal.CalBackendSyncClass.discard_alarm_sync

Discard alarm.

###### EDataCal.CalBackendSyncClass.get_attachment_uris_sync

Get attachments uris for given object.

###### EDataCal.CalBackendSyncClass.get_free_busy_sync

Get Free/Busy objects.

###### EDataCal.CalBackendSyncClass.get_object_list_sync

Get multiple objects at once.

###### EDataCal.CalBackendSyncClass.get_object_sync

Get single object.

###### EDataCal.CalBackendSyncClass.get_timezone_sync

Get specified timezone.

###### EDataCal.CalBackendSyncClass.modify_objects_sync

Modify objects.

###### EDataCal.CalBackendSyncClass.open_sync

Open the calendar.

###### EDataCal.CalBackendSyncClass.receive_objects_sync

Receive objects.

###### EDataCal.CalBackendSyncClass.refresh_sync

Refresh the calendar.

###### EDataCal.CalBackendSyncClass.remove_objects_sync

Remove objects.

###### EDataCal.CalBackendSyncClass.send_objects_sync

Send objects.