Gom.Filter

g GObject.InitiallyUnowned GObject.InitiallyUnowned Gom.Filter Gom.Filter GObject.InitiallyUnowned->Gom.Filter GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

new_and (left, right)

class

new_and_fullv (filter_array)

class

new_eq (resource_type, property_name, value)

class

new_glob (resource_type, property_name, value)

class

new_gt (resource_type, property_name, value)

class

new_gte (resource_type, property_name, value)

class

new_is_not_null (resource_type, property_name)

class

new_is_null (resource_type, property_name)

class

new_like (resource_type, property_name, value)

class

new_lt (resource_type, property_name, value)

class

new_lte (resource_type, property_name, value)

class

new_neq (resource_type, property_name, value)

class

new_or (left, right)

class

new_or_fullv (filter_array)

class

new_sql (sql, values)

get_sql (table_map)

get_values ()

Virtual Methods

Inherited:

GObject.Object (7)

Properties

Name

Type

Flags

Short Description

mode

Gom.FilterMode

r/w/co

The mode of the filter.

sql

str

w/co

The SQL for the filter.

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent

GObject.Object

r

Class Details

class Gom.Filter(**kwargs)
Bases:

GObject.InitiallyUnowned

Abstract:

No

Structure:

Gom.FilterClass

classmethod new_and(left, right)
Parameters:
Returns:

A Gom.Filter.

Return type:

Gom.Filter

Creates a new filter that requires that both left and right filters equate to True.

classmethod new_and_fullv(filter_array)
Parameters:

filter_array (Gom.Filter) – A None-terminated array of Gom.Filter.

Returns:

A Gom.Filter.

Return type:

Gom.Filter

Creates a new filter that requires that all filters passed as arguments equate to True.

classmethod new_eq(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_glob(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_gt(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_gte(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_is_not_null(resource_type, property_name)
Parameters:
Return type:

Gom.Filter

classmethod new_is_null(resource_type, property_name)
Parameters:
Return type:

Gom.Filter

classmethod new_like(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_lt(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_lte(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_neq(resource_type, property_name, value)
Parameters:
Return type:

Gom.Filter

classmethod new_or(left, right)
Parameters:
Returns:

A Gom.Filter.

Return type:

Gom.Filter

Creates a new filter that requires either the left or right filters equate to True.

classmethod new_or_fullv(filter_array)
Parameters:

filter_array (Gom.Filter) – A None-terminated array of Gom.Filter.

Returns:

A Gom.Filter.

Return type:

Gom.Filter

Creates a new filter that requires either of the filters passed as arguments equate to True.

classmethod new_sql(sql, values)
Parameters:
  • sql (str) – A UTF-8 string.

  • values ([GObject.Value]) – An array of values.

Returns:

A new Gom.Filter.

Return type:

Gom.Filter

Creates a new Gom.Filter using the SQL and values provided.

get_sql(table_map)
Parameters:

table_map ({object: object}) –

Return type:

str

get_values()
Returns:

An array of values for the SQL.

Return type:

[GObject.Value]

Fetches the list of values that should be applied in order when building the Gom.Command.

Property Details

Gom.Filter.props.mode
Name:

mode

Type:

Gom.FilterMode

Default Value:

Gom.FilterMode.SQL

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The mode of the filter.

Gom.Filter.props.sql
Name:

sql

Type:

str

Default Value:

None

Flags:

WRITABLE, CONSTRUCT_ONLY

The SQL for the filter.