Interface

IdeSessionAddin

Description

interface Ide.SessionAddin : Ide.Object
No description available.

Prerequisite

In order to implement SessionAddin, your type must inherit from IdeObject.

Instance methods

ide_session_addin_can_save_page

Checks whether self supports saving page. This is typically done by checking for its GObject type using FOO_IS_BAR_PAGE () for page types defined in the plugin. In practice it means that this self addin supports all the different vfuncs for this page.

Available since: 41

ide_session_addin_get_autosave_properties

For the pages supported by its ide_session_addin_can_save_page() function, gets a list of properties names that should be watched for changes on this page using the GObject notify mechanism. So given an array with “foo” and “bar”, the IdeSession will connect to the “notify::foo” and “notify::bar” signals and schedule a saving operation for some minutes later, so saving operations are grouped together.

Available since: 41.0

ide_session_addin_restore_page_async

Asynchronously requests that addin self restore a page’s session state with the provided state, previously saved by this addin using ide_session_addin_save_page_async(). This only happens when opening a project.

Available since: 41

ide_session_addin_restore_page_finish

Completes an asynchronous request to restore a page’s session state.

Available since: 41

ide_session_addin_save_page_async

Asynchronous request to save a page’s session state.

Available since: 41

ide_session_addin_save_page_finish

Completes an asynchronous request to save a page’s session state.

Available since: 41

Interface structure

struct IdeSessionAddinInterface {
  GTypeInterface parent;
  void (* save_page_async) (
    IdeSessionAddin* self,
    IdePage* page,
    GCancellable* cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data
  );
  GVariant* (* save_page_finish) (
    IdeSessionAddin* self,
    GAsyncResult* result,
    GError** error
  );
  void (* restore_page_async) (
    IdeSessionAddin* self,
    GVariant* state,
    GCancellable* cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data
  );
  IdePage* (* restore_page_finish) (
    IdeSessionAddin* self,
    GAsyncResult* result,
    GError** error
  );
  gboolean (* can_save_page) (
    IdeSessionAddin* self,
    IdePage* page
  );
  char** (* get_autosave_properties) (
    IdeSessionAddin* self
  );
  
}
Interface members
parent
GTypeInterface
 No description available.
save_page_async
void (* save_page_async) (
    IdeSessionAddin* self,
    IdePage* page,
    GCancellable* cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data
  )
 No description available.
save_page_finish
GVariant* (* save_page_finish) (
    IdeSessionAddin* self,
    GAsyncResult* result,
    GError** error
  )
 No description available.
restore_page_async
void (* restore_page_async) (
    IdeSessionAddin* self,
    GVariant* state,
    GCancellable* cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data
  )
 No description available.
restore_page_finish
IdePage* (* restore_page_finish) (
    IdeSessionAddin* self,
    GAsyncResult* result,
    GError** error
  )
 No description available.
can_save_page
gboolean (* can_save_page) (
    IdeSessionAddin* self,
    IdePage* page
  )
 No description available.
get_autosave_properties
char** (* get_autosave_properties) (
    IdeSessionAddin* self
  )
 No description available.

Virtual methods

Ide.SessionAddin.can_save_page

Checks whether self supports saving page. This is typically done by checking for its GObject type using FOO_IS_BAR_PAGE () for page types defined in the plugin. In practice it means that this self addin supports all the different vfuncs for this page.

Ide.SessionAddin.get_autosave_properties

For the pages supported by its ide_session_addin_can_save_page() function, gets a list of properties names that should be watched for changes on this page using the GObject notify mechanism. So given an array with “foo” and “bar”, the IdeSession will connect to the “notify::foo” and “notify::bar” signals and schedule a saving operation for some minutes later, so saving operations are grouped together.

Ide.SessionAddin.restore_page_async

Asynchronously requests that addin self restore a page’s session state with the provided state, previously saved by this addin using ide_session_addin_save_page_async(). This only happens when opening a project.

Ide.SessionAddin.restore_page_finish

Completes an asynchronous request to restore a page’s session state.

Ide.SessionAddin.save_page_async

Asynchronous request to save a page’s session state.

Ide.SessionAddin.save_page_finish

Completes an asynchronous request to save a page’s session state.