GDataFreebaseQuery: GData Reference Manual

## GDataFreebaseQuery GDataFreebaseQuery — GData Freebase query object |

## Stability Level

Stable, unless otherwise indicated

## Functions

GDataFreebaseQuery * | gdata_freebase_query_new ()
GDataFreebaseQuery * | gdata_freebase_query_new_from_variant ()

## Properties

GVariant * | variant | Read / Write / Construct Only

## Types and Values

| GDataFreebaseQuery
| GDataFreebaseQueryClass

## Object Hierarchy

        GObject
        ╰── GDataQuery
            ╰── GDataFreebaseQuery

## Includes

    #include <gdata/services/freebase/gdata-freebase-query.h>

## Description

GDataFreebaseQuery represents a MQL query specific to the Google Freebase service.

This implementation of GDataQuery respects the `gdata_query_set_max_results()` call.

For more details of Google Freebase API, see the online documentation.

## Functions

### gdata_freebase_query_new ()

    GDataFreebaseQuery *
    gdata_freebase_query_new (const gchar *mql);

`gdata_freebase_query_new` has been deprecated since version 0.17.7 and should not be used in newly-written code.

Google Freebase has been permanently shut down.

Creates a new GDataFreebaseQuery with the MQL query provided in `mql` . MQL is a JSON-based query language, analogous to SPARQL. To learn more about MQL, see the MQL overview and cookbook.

For detailed information on Freebase schemas, The "Schema" section on the main site allows for natural search and navigation through the multiple data properties and domains.

#### Parameters

mql | a MQL query string |

#### Returns

a new GDataFreebaseQuery.

[transfer full]

Since: 0.15.1

### gdata_freebase_query_new_from_variant ()

    GDataFreebaseQuery *
    gdata_freebase_query_new_from_variant (GVariant *variant);

`gdata_freebase_query_new_from_variant` has been deprecated since version 0.17.7 and should not be used in newly-written code.

Google Freebase has been permanently shut down.

Creates a new GDataFreebaseQuery with the MQL query provided in a serialized form as `variant` of type "a{smv}" containing the JSON data tree of a MQL query. One convenient way to build the variant is using `json_gvariant_serialize()` from a JsonNode. For more information about MQL, see `gdata_freebase_query_new()`.

GDataFreebaseQuery takes ownership on `variant` , if it has a floating reference, it will be sunk. Otherwise an extra reference will be added.

#### Parameters

variant | a variant containing the MQL query structure |

#### Returns

a new GDataFreebaseQuery.

[transfer full]

Since: 0.15.1

## Types and Values

### GDataFreebaseQuery

    typedef struct _GDataFreebaseQuery GDataFreebaseQuery;

`GDataFreebaseQuery` is deprecated and should not be used in newly-written code.

All the fields in the GDataFreebaseQuery structure are private and should never be accessed directly.

Since: 0.15.1

### GDataFreebaseQueryClass

    typedef struct {
    } GDataFreebaseQueryClass;

`GDataFreebaseQueryClass` is deprecated and should not be used in newly-written code.

All the fields in the GDataFreebaseQueryClass structure are private and should never be accessed directly.

Since: 0.15.1

## Property Details

### The `“variant”` property

      “variant”                  GVariant *

Variant containing the MQL query. The variant is a very generic container of type "a{smv}", containing (possibly nested) Freebase schema types and values.

`GDataFreebaseQuery:variant` has been deprecated since version 0.17.7 and should not be used in newly-written code.

Google Freebase has been permanently shut down.

Flags: Read / Write / Construct Only

Allowed values: GVariant<a{smv}>

Default value: NULL

Since: 0.15.1