Interface
Object Hierarchy:
Description:
[ GIR ( visible = false ) ]
public interface Interface : Object
Live proxy that takes the wire lease as a construct property.
Bin.Stream.parse_object calls
GLib.Object.new with rpc-lid on the live path. Stub construct reads
rpc_lid (non-zero → already leased; skip Ns-Type.new
). Construct setters that run before that block stash values with
rpc_ctor_stash and read them back with rpc_ctor_get.
[GIR (visible = false)] marks this interface non-introspectable. Stock Vala still emits an implements edge for it on every public
consumer class. That edge names a library with no typelib, and GJS crashes while resolving methods. Hide it one of two ways: build with
the Vala patch that skips non-introspectable interfaces (girwriter-hidden-interface-implements), or strip implements name
OLLMrpc.LiveInterface with XSLT before g-ir-compiler. gnome-shell-rpc does the strip in scripts/gir-inject.xsl.
Example
public class Actor : GLib.Object, OLLMrpc.Live.Interface {
public uint64 rpc_lid { get; set construct; default = 0; }
construct {
if (this.rpc_lid != 0) {
return;
}
// else create remote peer and set rpc_lid
}
}
Content:
Properties:
Methods:
- public void rpc_ctor_clear ()
Drop the construct stash. Safe when nothing was stored.
- public Value? rpc_ctor_get (string name)
Stashed construct value for one property.
- public bool rpc_ctor_has (string wire)
Whether stashed construct arguments belong to this wire name.
- public void rpc_ctor_stash (string name, Value value)
Copy one construct property onto this instance.
Inherited Members:
All known members inherited from class GLib.Object
- @get
- @new
- @ref
- @set
- add_toggle_ref
- add_weak_pointer
- bind_property
- connect
- constructed
- disconnect
- dispose
- dup_data
- dup_qdata
- force_floating
- freeze_notify
- get_class
- get_data
- get_property
- get_qdata
- get_type
- getv
- interface_find_property
- interface_install_property
- interface_list_properties
- is_floating
- new_valist
- new_with_properties
- newv
- notify
- notify_property
- ref_count
- ref_sink
- remove_toggle_ref
- remove_weak_pointer
- replace_data
- replace_qdata
- set_data
- set_data_full
- set_property
- set_qdata
- set_qdata_full
- set_valist
- setv
- steal_data
- steal_qdata
- thaw_notify
- unref
- watch_closure
- weak_ref
- weak_unref