EDataServer.OAuth2Service.extract_error_message
Description: Reference for EDataServer.OAuth2Service.extract_error_message

### Virtual Method

# EDataServer OAuth2Serviceextract_error_message

since: 3.48

#### Declaration [src]

    gboolean
    extract_error_message (
      EOAuth2Service* service,
      ESource* source,
      const gchar* page_title,
      const gchar* page_uri,
      const gchar* page_content,
      gchar** out_error_message
    )

#### Description [src]

Tries to extract error message from the server response, return `TRUE`, when an error message could be found, in which case also sets the `out_error_message` with it. The default implementation uses e_oauth2_service_util_extract_from_uri(), returning either the error description or the error code, when the description is not found.

The `out_error_message` is expected to be plain text.

Available since: 3.48

#### Parameters

`source`

  Type: `ESource`

  An associated `ESource`.

  The data is owned by the caller of the method.

`page_title`

  Type: `const gchar*`

  A web page title.

  The data is owned by the caller of the method.
  The value is a NUL terminated UTF-8 string.

`page_uri`

  Type: `const gchar*`

  A web page URI.

  The data is owned by the caller of the method.
  The value is a NUL terminated UTF-8 string.

`page_content`

  Type: `const gchar*`

  A web page content.

  The argument can be `NULL`.
  The data is owned by the caller of the method.
  The value is a NUL terminated UTF-8 string.

`out_error_message`

  Type: `gchar**`

  The extracted error message.

  The argument will be set by the function.
  The caller of the method takes ownership of the returned data, and is responsible for freeing it.
  The value is a NUL terminated UTF-8 string.

#### Return value

Type: `gboolean`

Whether could recognized failed server response. The `out_error_message` is populated on success.