ExpressionWatchProtocol
public protocol ExpressionWatchProtocol
An opaque structure representing a watched GtkExpression.
The contents of GtkExpressionWatch should only be accessed through the
provided API.
The ExpressionWatchProtocol protocol exposes the methods and properties of an underlying GtkExpressionWatch instance.
The default implementation of these can be found in the protocol extension below.
For a concrete class that implements these methods and properties, see ExpressionWatch.
Alternatively, use ExpressionWatchRef as a lighweight, unowned reference if you already have an instance you just want to use.
-
Untyped pointer to the underlying
GtkExpressionWatchinstance.Declaration
Swift
var ptr: UnsafeMutableRawPointer! { get } -
expression_watch_ptrDefault implementationTyped pointer to the underlying
GtkExpressionWatchinstance.Default Implementation
Return the stored, untyped pointer as a typed pointer to the
GtkExpressionWatchinstance.Declaration
Swift
var expression_watch_ptr: UnsafeMutablePointer<GtkExpressionWatch>! { get } -
Required Initialiser for types conforming to
ExpressionWatchProtocolDeclaration
Swift
init(raw: UnsafeMutableRawPointer)
-
evaluate(value:Extension method) Evaluates the watched expression and on success stores the result in
value.This is equivalent to calling [method
Gtk.Expression.evaluate] with the expression and this pointer originally used to createwatch.Declaration
Swift
@inlinable func evaluate<ValueT>(value: ValueT) -> Bool where ValueT : ValueProtocol -
ref()Extension methodAcquires a reference on the given
GtkExpressionWatch.Declaration
Swift
@discardableResult @inlinable func ref() -> ExpressionWatchRef! -
unref()Extension methodReleases a reference on the given
GtkExpressionWatch.If the reference was the last, the resources associated to
selfare freed.Declaration
Swift
@inlinable func unref() -
unwatch()Extension methodStops watching an expression.
See [method
Gtk.Expression.watch] for how the watch was established.Declaration
Swift
@inlinable func unwatch()
View on GitHub
Install in Dash
ExpressionWatchProtocol Protocol Reference