Struct fractal::session::model::room::event::Event

source ·
#[repr(transparent)]
pub struct Event { inner: TypedObjectRef<Event, <Event as ObjectSubclass>::ParentType>, phantom: PhantomData<()>, }
Expand description

GObject representation of a Matrix room event.

GLib type: GObject with reference counted clone semantics.

Fields§

§inner: TypedObjectRef<Event, <Event as ObjectSubclass>::ParentType>§phantom: PhantomData<()>

Implementations§

source§

impl Event

source

pub fn room(&self) -> <OnceCell<Room> as Property>::Value

source

pub fn reactions(&self) -> <ReactionList as Property>::Value

source

pub fn read_receipts(&self) -> <ListStore as Property>::Value

source

pub fn state(&self) -> <Cell<MessageState> as Property>::Value

source

pub fn source(&self) -> <PhantomData<Option<String>> as Property>::Value

source

pub fn has_source(&self) -> <PhantomData<bool> as Property>::Value

source

pub fn event_id_string( &self, ) -> <PhantomData<Option<String>> as Property>::Value

source

pub fn timeline_id(&self) -> <String as Property>::Value

source

pub fn sender_id_string(&self) -> <PhantomData<String> as Property>::Value

source

pub fn timestamp(&self) -> <PhantomData<DateTime> as Property>::Value

source

pub fn timestamp_full(&self) -> <PhantomData<String> as Property>::Value

source

pub fn is_edited(&self) -> <PhantomData<bool> as Property>::Value

source

pub fn latest_edit_source(&self) -> <PhantomData<String> as Property>::Value

source

pub fn latest_edit_event_id_string( &self, ) -> <PhantomData<String> as Property>::Value

source

pub fn latest_edit_timestamp( &self, ) -> <PhantomData<Option<DateTime>> as Property>::Value

source

pub fn latest_edit_timestamp_full( &self, ) -> <PhantomData<String> as Property>::Value

source

pub fn is_highlighted(&self) -> <PhantomData<bool> as Property>::Value

source

pub fn has_read_receipts(&self) -> <PhantomData<bool> as Property>::Value

source

pub fn connect_room_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_reactions_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_read_receipts_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_state_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_source_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_has_source_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_event_id_string_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_timeline_id_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_sender_id_string_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_timestamp_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_timestamp_full_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_is_edited_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_latest_edit_source_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_latest_edit_event_id_string_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_latest_edit_timestamp_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_latest_edit_timestamp_full_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_is_highlighted_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn connect_has_read_receipts_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

source

pub fn notify_room(&self)

source

pub fn notify_reactions(&self)

source

pub fn notify_read_receipts(&self)

source

pub fn notify_state(&self)

source

pub fn notify_source(&self)

source

pub fn notify_has_source(&self)

source

pub fn notify_event_id_string(&self)

source

pub fn notify_timeline_id(&self)

source

pub fn notify_sender_id_string(&self)

source

pub fn notify_timestamp(&self)

source

pub fn notify_timestamp_full(&self)

source

pub fn notify_is_edited(&self)

source

pub fn notify_latest_edit_source(&self)

source

pub fn notify_latest_edit_event_id_string(&self)

source

pub fn notify_latest_edit_timestamp(&self)

source

pub fn notify_latest_edit_timestamp_full(&self)

source

pub fn notify_is_highlighted(&self)

source

pub fn notify_has_read_receipts(&self)

source§

impl Event

source

pub fn new(item: EventTimelineItem, timeline_id: &str, room: &Room) -> Self

Create a new Event with the given SDK timeline item.

source

pub fn try_update_with( &self, item: &EventTimelineItem, timeline_id: &str, ) -> bool

Try to update this Event with the given SDK timeline item.

Returns true if the update succeeded.

source

pub fn item(&self) -> EventTimelineItem

The underlying SDK timeline item.

source

pub fn raw(&self) -> Option<Raw<AnySyncTimelineEvent>>

The raw JSON source for this Event, if it has been echoed back by the server.

source

pub fn key(&self) -> EventKey

The unique key of this Event in the timeline.

source

pub fn matches_key(&self, key: &EventKey) -> bool

Whether the given key matches this Event.

The result can be different from comparing two EventKeys because an event can have a transaction ID and an event ID.

source

pub fn event_id(&self) -> Option<OwnedEventId>

The event ID of this Event, if it has been received from the server.

source

pub fn transaction_id(&self) -> Option<OwnedTransactionId>

The transaction ID of this Event, if it is still pending.

source

pub fn sender_id(&self) -> OwnedUserId

The user ID of the sender of this Event.

source

pub fn sender(&self) -> Member

The sender of this Event.

This should only be called when the event’s room members list is available, otherwise it will be created on every call.

source

pub fn origin_server_ts(&self) -> MilliSecondsSinceUnixEpoch

The timestamp of this Event as the number of milliseconds since Unix Epoch, if it has been echoed back by the server.

Otherwise it’s the local time when this event was created.

source

pub fn origin_server_ts_u64(&self) -> u64

The timestamp of this Event as a u64, if it has been echoed back by the server.

Otherwise it’s the local time when this event was created.

source

pub fn is_redacted(&self) -> bool

Whether this Event is redacted.

source

pub fn content(&self) -> TimelineItemContent

The content to display for this Event.

source

pub fn message(&self) -> Option<MessageType>

The message of this Event, if any.

source

pub fn media_message(&self) -> Option<MediaMessage>

The media message of this Event, if any.

source

pub fn visual_media_message(&self) -> Option<VisualMediaMessage>

The visual media message of this Event, if any.

source

pub fn mentions(&self) -> Option<Mentions>

The mentions from this message, if any.

source

pub fn can_contain_at_room(&self) -> bool

Whether this event might contain an @room mention.

This means that either it doesn’t have intentional mentions, or it has intentional mentions and room is set to true.

source

fn compute_state(&self) -> MessageState

Compute the current state of this Event.

source

fn update_state(&self)

Update the state of this Event.

source

fn update_read_receipts( &self, new_read_receipts: &IndexMap<OwnedUserId, Receipt>, )

Update the read receipts list with the given receipts.

source

pub fn reply_to_id(&self) -> Option<OwnedEventId>

Get the ID of the event this Event replies to, if any.

source

pub fn is_reply(&self) -> bool

Whether this Event is a reply to another event.

source

pub fn reply_to_event_content( &self, ) -> Option<TimelineDetails<Box<RepliedToEvent>>>

Get the details of the event this Event replies to, if any.

Returns None(_) if this event is not a reply.

source

pub fn reply_to_event(&self) -> Option<Event>

Get the event this Event replies to, if any.

Returns None(_) if this event is not a reply or if the event was not found locally.

source

pub async fn fetch_missing_details(&self) -> Result<(), TimelineError>

Fetch missing details for this event.

This is a no-op if called for a local event.

source

pub fn is_message(&self) -> bool

Whether this Event is considered a message.

source

pub fn as_message(&self) -> Option<OriginalSyncRoomMessageEvent>

Deserialize this Event as an OriginalSyncRoomMessageEvent, if possible.

source

pub fn counts_as_unread(&self) -> bool

Whether this Event can count as an unread message.

This follows the algorithm in MSC2654, excluding events that we don’t show in the timeline.

source

pub async fn matrix_to_uri(&self) -> Option<MatrixToUri>

The matrix.to URI representation for this event.

Returns None if we don’t have the ID of the event.

source

pub async fn matrix_uri(&self) -> Option<MatrixUri>

The matrix: URI representation for this event.

Returns None if we don’t have the ID of the event.

source

pub fn connect_item_changed<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Listen to the signal emitted when the SDK item changed.

Trait Implementations§

source§

impl Clone for Event

source§

fn clone(&self) -> Self

Makes a clone of this shared reference.

This increments the strong reference count of the object. Dropping the object will decrement it again.

1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Event

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl HasParamSpec for Event

source§

type ParamSpec = ParamSpecObject

source§

type SetValue = Event

Preferred value to be used as setter for the associated ParamSpec.
source§

type BuilderFn = fn(_: &str) -> ParamSpecObjectBuilder<'_, Event>

source§

fn param_spec_builder() -> Self::BuilderFn

source§

impl Hash for Event

source§

fn hash<H>(&self, state: &mut H)
where H: Hasher,

Hashes the memory address of this object.

1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl ObjectSubclassIs for Event

source§

impl Ord for Event

source§

fn cmp(&self, other: &Self) -> Ordering

Comparison for two GObjects.

Compares the memory addresses of the provided objects.

1.21.0 · source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl ParentClassIs for Event

source§

impl<OT: ObjectType> PartialEq<OT> for Event

source§

fn eq(&self, other: &OT) -> bool

Equality for two GObjects.

Two GObjects are equal if their memory addresses are equal.

1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<OT: ObjectType> PartialOrd<OT> for Event

source§

fn partial_cmp(&self, other: &OT) -> Option<Ordering>

Partial comparison for two GObjects.

Compares the memory addresses of the provided objects.

1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl StaticType for Event

source§

fn static_type() -> Type

Returns the type identifier of Self.
source§

impl Eq for Event

source§

impl IsA<TimelineItem> for Event

Auto Trait Implementations§

§

impl Freeze for Event

§

impl !RefUnwindSafe for Event

§

impl !Send for Event

§

impl !Sync for Event

§

impl Unpin for Event

§

impl !UnwindSafe for Event

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> Cast for T
where T: ObjectType,

source§

fn upcast<T>(self) -> T
where T: ObjectType, Self: IsA<T>,

Upcasts an object to a superclass or interface T. Read more
source§

fn upcast_ref<T>(&self) -> &T
where T: ObjectType, Self: IsA<T>,

Upcasts an object to a reference of its superclass or interface T. Read more
source§

fn downcast<T>(self) -> Result<T, Self>
where T: ObjectType, Self: MayDowncastTo<T>,

Tries to downcast to a subclass or interface implementor T. Read more
source§

fn downcast_ref<T>(&self) -> Option<&T>
where T: ObjectType, Self: MayDowncastTo<T>,

Tries to downcast to a reference of its subclass or interface implementor T. Read more
source§

fn dynamic_cast<T>(self) -> Result<T, Self>
where T: ObjectType,

Tries to cast to an object of type T. This handles upcasting, downcasting and casting between interface and interface implementors. All checks are performed at runtime, while upcast will do many checks at compile-time already. downcast will perform the same checks at runtime as dynamic_cast, but will also ensure some amount of compile-time safety. Read more
source§

fn dynamic_cast_ref<T>(&self) -> Option<&T>
where T: ObjectType,

Tries to cast to reference to an object of type T. This handles upcasting, downcasting and casting between interface and interface implementors. All checks are performed at runtime, while downcast and upcast will do many checks at compile-time already. Read more
source§

unsafe fn unsafe_cast<T>(self) -> T
where T: ObjectType,

Casts to T unconditionally. Read more
source§

unsafe fn unsafe_cast_ref<T>(&self) -> &T
where T: ObjectType,

Casts to &T unconditionally. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<Q, K> Comparable<K> for Q
where Q: Ord + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn compare(&self, key: &K) -> Ordering

Compare self to key and return their ordering.
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for T

source§

impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for T

source§

impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for T

source§

impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for T

source§

impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for T

source§

impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for T

source§

impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for T

source§

impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for T

source§

impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for T

source§

impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for T

source§

impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for T

source§

impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for T

source§

impl<T> FromRef<T> for T
where T: Clone,

source§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
source§

impl<O> GObjectExtManualGst for O
where O: IsA<Object>,

source§

fn set_property_from_str(&self, name: &str, value: &str)

source§

impl<O> GObjectPropertyExpressionExt for O
where O: IsA<Object>,

source§

fn property_expression(&self, property_name: &str) -> PropertyExpression

Create an expression looking up an object’s property.
source§

fn property_expression_weak(&self, property_name: &str) -> PropertyExpression

Create an expression looking up an object’s property with a weak reference.
source§

fn this_expression(property_name: &str) -> PropertyExpression

Create an expression looking up a property in the bound this object.
source§

impl<T, W> HasTypeWitness<W> for T
where W: MakeTypeWitness<Arg = T>, T: ?Sized,

source§

const WITNESS: W = W::MAKE

A constant of the type witness
source§

impl<T> Identity for T
where T: ?Sized,

source§

const TYPE_EQ: TypeEq<T, <T as Identity>::Type> = TypeEq::NEW

Proof that Self is the same type as Self::Type, provides methods for casting between Self and Self::Type.
source§

type Type = T

The same type as Self, used to emulate type equality bounds (T == U) with associated type equality constraints (T: Identity<Type = U>).
source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoClosureReturnValue for T
where T: Into<Value>,

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<U> IsSubclassableExt for U

source§

impl<T> ObjectExt for T
where T: ObjectType,

source§

fn is<U>(&self) -> bool
where U: StaticType,

Returns true if the object is an instance of (can be cast to) T.
source§

fn type_(&self) -> Type

Returns the type of the object.
source§

fn object_class(&self) -> &Class<Object>

Returns the ObjectClass of the object. Read more
source§

fn class(&self) -> &Class<T>
where T: IsClass,

Returns the class of the object.
source§

fn class_of<U>(&self) -> Option<&Class<U>>
where U: IsClass,

Returns the class of the object in the given type T. Read more
source§

fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>
where U: IsInterface,

Returns the interface T of the object. Read more
source§

fn set_property(&self, property_name: &str, value: impl Into<Value>)

Sets the property property_name of the object to value value. Read more
source§

fn set_property_from_value(&self, property_name: &str, value: &Value)

Sets the property property_name of the object to value value. Read more
source§

fn set_properties(&self, property_values: &[(&str, &dyn ToValue)])

Sets multiple properties of the object at once. Read more
source§

fn set_properties_from_value(&self, property_values: &[(&str, Value)])

Sets multiple properties of the object at once. Read more
source§

fn property<V>(&self, property_name: &str) -> V
where V: for<'b> FromValue<'b> + 'static,

Gets the property property_name of the object and cast it to the type V. Read more
source§

fn property_value(&self, property_name: &str) -> Value

Gets the property property_name of the object. Read more
source§

fn has_property(&self, property_name: &str, type_: Option<Type>) -> bool

Check if the object has a property property_name of the given type_. Read more
source§

fn property_type(&self, property_name: &str) -> Option<Type>

Get the type of the property property_name of this object. Read more
source§

fn find_property(&self, property_name: &str) -> Option<ParamSpec>

Get the ParamSpec of the property property_name of this object.
source§

fn list_properties(&self) -> PtrSlice<ParamSpec>

Return all ParamSpec of the properties of this object.
source§

fn freeze_notify(&self) -> PropertyNotificationFreezeGuard

Freeze all property notifications until the return guard object is dropped. Read more
source§

unsafe fn set_qdata<QD>(&self, key: Quark, value: QD)
where QD: 'static,

Set arbitrary data on this object with the given key. Read more
source§

unsafe fn qdata<QD>(&self, key: Quark) -> Option<NonNull<QD>>
where QD: 'static,

Return previously set arbitrary data of this object with the given key. Read more
source§

unsafe fn steal_qdata<QD>(&self, key: Quark) -> Option<QD>
where QD: 'static,

Retrieve previously set arbitrary data of this object with the given key. Read more
source§

unsafe fn set_data<QD>(&self, key: &str, value: QD)
where QD: 'static,

Set arbitrary data on this object with the given key. Read more
source§

unsafe fn data<QD>(&self, key: &str) -> Option<NonNull<QD>>
where QD: 'static,

Return previously set arbitrary data of this object with the given key. Read more
source§

unsafe fn steal_data<QD>(&self, key: &str) -> Option<QD>
where QD: 'static,

Retrieve previously set arbitrary data of this object with the given key. Read more
source§

fn block_signal(&self, handler_id: &SignalHandlerId)

Block a given signal handler. Read more
source§

fn unblock_signal(&self, handler_id: &SignalHandlerId)

Unblock a given signal handler.
source§

fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)

Stop emission of the currently emitted signal.
source§

fn stop_signal_emission_by_name(&self, signal_name: &str)

Stop emission of the currently emitted signal by the (possibly detailed) signal name.
source§

fn connect<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
where F: Fn(&[Value]) -> Option<Value> + Send + Sync + 'static,

Connect to the signal signal_name on this object. Read more
source§

fn connect_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
where F: Fn(&[Value]) -> Option<Value> + Send + Sync + 'static,

Connect to the signal signal_id on this object. Read more
source§

fn connect_local<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
where F: Fn(&[Value]) -> Option<Value> + 'static,

Connect to the signal signal_name on this object. Read more
source§

fn connect_local_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
where F: Fn(&[Value]) -> Option<Value> + 'static,

Connect to the signal signal_id on this object. Read more
source§

unsafe fn connect_unsafe<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
where F: Fn(&[Value]) -> Option<Value>,

Connect to the signal signal_name on this object. Read more
source§

unsafe fn connect_unsafe_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
where F: Fn(&[Value]) -> Option<Value>,

Connect to the signal signal_id on this object. Read more
source§

fn connect_closure( &self, signal_name: &str, after: bool, closure: RustClosure, ) -> SignalHandlerId

Connect a closure to the signal signal_name on this object. Read more
source§

fn connect_closure_id( &self, signal_id: SignalId, details: Option<Quark>, after: bool, closure: RustClosure, ) -> SignalHandlerId

Connect a closure to the signal signal_id on this object. Read more
source§

fn watch_closure(&self, closure: &impl AsRef<Closure>)

Limits the lifetime of closure to the lifetime of the object. When the object’s reference count drops to zero, the closure will be invalidated. An invalidated closure will ignore any calls to invoke_with_values, or invoke when using Rust closures.
source§

fn emit<R>(&self, signal_id: SignalId, args: &[&dyn ToValue]) -> R

Emit signal by signal id. Read more
source§

fn emit_with_values(&self, signal_id: SignalId, args: &[Value]) -> Option<Value>

Same as Self::emit but takes Value for the arguments.
source§

fn emit_by_name<R>(&self, signal_name: &str, args: &[&dyn ToValue]) -> R

Emit signal by its name. Read more
source§

fn emit_by_name_with_values( &self, signal_name: &str, args: &[Value], ) -> Option<Value>

Emit signal by its name. Read more
source§

fn emit_by_name_with_details<R>( &self, signal_name: &str, details: Quark, args: &[&dyn ToValue], ) -> R

Emit signal by its name with details. Read more
source§

fn emit_by_name_with_details_and_values( &self, signal_name: &str, details: Quark, args: &[Value], ) -> Option<Value>

Emit signal by its name with details. Read more
source§

fn emit_with_details<R>( &self, signal_id: SignalId, details: Quark, args: &[&dyn ToValue], ) -> R

Emit signal by signal id with details. Read more
source§

fn emit_with_details_and_values( &self, signal_id: SignalId, details: Quark, args: &[Value], ) -> Option<Value>

Emit signal by signal id with details. Read more
source§

fn disconnect(&self, handler_id: SignalHandlerId)

Disconnect a previously connected signal handler.
source§

fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
where F: Fn(&T, &ParamSpec) + Send + Sync + 'static,

Connect to the notify signal of the object. Read more
source§

fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
where F: Fn(&T, &ParamSpec) + 'static,

Connect to the notify signal of the object. Read more
source§

unsafe fn connect_notify_unsafe<F>( &self, name: Option<&str>, f: F, ) -> SignalHandlerId
where F: Fn(&T, &ParamSpec),

Connect to the notify signal of the object. Read more
source§

fn notify(&self, property_name: &str)

Notify that the given property has changed its value. Read more
source§

fn notify_by_pspec(&self, pspec: &ParamSpec)

Notify that the given property has changed its value. Read more
source§

fn downgrade(&self) -> WeakRef<T>

Downgrade this object to a weak reference.
source§

fn add_weak_ref_notify<F>(&self, f: F) -> WeakRefNotify<T>
where F: FnOnce() + Send + 'static,

Add a callback to be notified when the Object is disposed.
source§

fn add_weak_ref_notify_local<F>(&self, f: F) -> WeakRefNotify<T>
where F: FnOnce() + 'static,

Add a callback to be notified when the Object is disposed. Read more
source§

fn bind_property<'a, 'f, 't, O>( &'a self, source_property: &'a str, target: &'a O, target_property: &'a str, ) -> BindingBuilder<'a, 'f, 't>
where O: ObjectType,

Bind property source_property on this object to the target_property on the target object. Read more
source§

fn ref_count(&self) -> u32

Returns the strong reference count of this object.
source§

unsafe fn run_dispose(&self)

Runs the dispose mechanism of the object. Read more
source§

impl<T, S> ObjectSubclassIsExt for T
where T: ObjectSubclassIs<Subclass = S>, S: ObjectSubclass<Type = T>,

source§

fn imp(&self) -> &<T as ObjectSubclassIs>::Subclass

Returns the implementation (the private Rust struct) of this class instance
source§

impl<T> Pointable for T

source§

const ALIGN: usize = _

The alignment of pointer.
source§

type Init = T

The type for initializers.
source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Property for T
where T: HasParamSpec,

source§

type Value = T

source§

impl<T> PropertyGet for T
where T: HasParamSpec,

source§

type Value = T

source§

fn get<R, F>(&self, f: F) -> R
where F: Fn(&<T as PropertyGet>::Value) -> R,

source§

impl<T> Same for T

source§

type Output = T

Should always be Self
source§

impl<T> StaticTypeExt for T
where T: StaticType,

source§

fn ensure_type()

Ensures that the type has been registered with the type system.
source§

impl<T> ToOwned for T
where T: Clone,

source§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> TransparentType for T

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T> TryFromClosureReturnValue for T
where T: for<'a> FromValue<'a> + StaticType + 'static,

source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

impl<T> Any for T
where T: Any,

source§

impl<T> CloneAny for T
where T: Any + Clone,

source§

impl<'a, T, C, E> FromValueOptional<'a> for T
where T: FromValue<'a, Checker = C>, C: ValueTypeChecker<Error = ValueTypeMismatchOrNoneError<E>>, E: Error + Send + 'static,

source§

impl<A, B, T> HttpServerConnExec<A, B> for T
where B: Body,

source§

impl<Super, Sub> MayDowncastTo<Sub> for Super
where Super: IsA<Super>, Sub: IsA<Super>,