Dazzle.ReadOnlyListModel

g Dazzle.ReadOnlyListModel Dazzle.ReadOnlyListModel GObject.GInterface GObject.GInterface Gio.ListModel Gio.ListModel GObject.GInterface->Gio.ListModel GObject.Object GObject.Object GObject.Object->Dazzle.ReadOnlyListModel Gio.ListModel->Dazzle.ReadOnlyListModel

Subclasses:

None

Methods

Inherited:

GObject.Object (37), Gio.ListModel (4)

Structs:

GObject.ObjectClass (5)

class

new (base_model)

Virtual Methods

Inherited:

GObject.Object (7), Gio.ListModel (3)

Properties

Name

Type

Flags

Short Description

base-model

Gio.ListModel

w/co

The list model to be wrapped as read-only

Signals

Inherited:

GObject.Object (1), Gio.ListModel (1)

Fields

Inherited:

GObject.Object (1), Gio.ListModel (1)

Class Details

class Dazzle.ReadOnlyListModel(**kwargs)
Bases:

GObject.Object, Gio.ListModel

Abstract:

No

Structure:

Dazzle.ReadOnlyListModelClass

classmethod new(base_model)
Parameters:

base_model (Gio.ListModel) – a Gio.ListModel

Returns:

a Dazzle.ReadOnlyListModel

Return type:

Gio.ListModel

Creates a new Dazzle.ReadOnlyListModel which is a read-only wrapper around base_model. This is useful when you want to give API consumers access to a Gio.ListModel but without the ability to mutate the underlying list.

New in version 3.30.

Property Details

Dazzle.ReadOnlyListModel.props.base_model
Name:

base-model

Type:

Gio.ListModel

Default Value:

None

Flags:

WRITABLE, CONSTRUCT_ONLY

The “base-model” property is the Gio.ListModel that will be wrapped.

This base model is not accessible after creation so that API creators can be sure the consumer cannot mutate the underlying model. That is useful when you want to give a caller access to a Gio.ListModel without the ability to introspect on the type and mutate it without your knowledge (such as with Gio.ListStore).

New in version 3.30.