gtkmm: Gtk::ExpressionWatch< T > Class Template Reference

gtkmm 4.12.0

Public Member Functions | List of all members
Gtk::ExpressionWatch< T > Class Template Referencefinal

`#include <gtkmm/expressionwatch.h>`

Inheritance diagram for Gtk::ExpressionWatch< T >:
[legend]

## Public Member Functions
std::optional< T > | evaluate ()
| Evaluates the watched expression and on success returns the result.
Public Member Functions inherited from Gtk::ExpressionWatchBase
void | reference () const
| Increment the reference count for this object.
void | unreference () const
| Decrement the reference count for this object.
GtkExpressionWatch * | gobj ()
| Provides access to the underlying C instance.
const GtkExpressionWatch * | gobj () const
| Provides access to the underlying C instance.
GtkExpressionWatch * | gobj_copy () const
| Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
| ExpressionWatchBase ()=delete
| ExpressionWatchBase (const ExpressionWatchBase &)=delete
ExpressionWatchBase & | operator= (const ExpressionWatchBase &)=delete
void | unwatch ()
| Stops watching an expression that was established via Gtk::Expression::watch().

## Additional Inherited Members
Protected Member Functions inherited from Gtk::ExpressionWatchBase
void | operator delete (void *, std::size_t)
Related Symbols inherited from Gtk::ExpressionWatchBase
Glib::RefPtr< Gtk::ExpressionWatchBase > | wrap (GtkExpressionWatch * object, bool take_copy=false)
| A Glib::wrap() method for this object.

## Member Function Documentation

## ◆ evaluate()

template <class T >

std::optional< T > Gtk::ExpressionWatch< T >::evaluate

Evaluates the watched expression and on success returns the result.

This is equivalent to calling Gtk::Expression::evaluate() with the expression and this pointer originally used to create the watch.

Returns
  The optional result of the evaluation.