morph 0.1.0
Asynchronous bridge between GUI thread and business models
Loading...
Searching...
No Matches
morph::ui::detail::ScopeResolver Class Referencefinal

Resolves an expression's names against a scope chain and a context. More...

#include <document.hpp>

Inheritance diagram for morph::ui::detail::ScopeResolver:
morph::ui::NameResolver

Public Member Functions

 ScopeResolver (DocumentValidator &validator, CheckContext const &context)
 Resolves for validator in context.
std::expected< Type, std::string > ref (std::string_view head, std::span< std::string const > path) const override
 Resolves a reference.
std::expected< Type, std::string > row (std::span< std::string const > path) const override
 Resolves a row field.
std::expected< Type, std::string > control (ExprKind form, std::string_view name) const override
 Resolves a query or mutation name.
std::expected< Type, std::string > pref (std::string_view point, std::span< std::string const > path) const override
 Resolves a customization point.
Public Member Functions inherited from morph::ui::NameResolver
 NameResolver (NameResolver const &)=delete
NameResolver & operator= (NameResolver const &)=delete
 NameResolver (NameResolver &&)=delete
NameResolver & operator= (NameResolver &&)=delete

Detailed Description

Resolves an expression's names against a scope chain and a context.

Definition at line 2172 of file document.hpp.

Constructor & Destructor Documentation

◆ ScopeResolver()

morph::ui::detail::ScopeResolver::ScopeResolver ( DocumentValidator & validator,
CheckContext const & context )
inline

Resolves for validator in context.

Parameters
validatorThe validator, which derives state and let types on demand.
contextWhere the expression is.

Definition at line 2177 of file document.hpp.

Member Function Documentation

◆ ref()

std::expected< Type, std::string > morph::ui::detail::ScopeResolver::ref ( std::string_view head,
std::span< std::string const > path ) const
inlinenodiscardoverridevirtual

Resolves a reference.

Parameters
headThe first segment.
pathThe rest.
Returns
The type, or why it does not resolve.

Implements morph::ui::NameResolver.

Definition at line 3669 of file document.hpp.

◆ row()

std::expected< Type, std::string > morph::ui::detail::ScopeResolver::row ( std::span< std::string const > path) const
inlinenodiscardoverridevirtual

Resolves a row field.

Parameters
pathThe field path.
Returns
any inside a row, or why there is no row.

Implements morph::ui::NameResolver.

Definition at line 3743 of file document.hpp.

◆ control()

std::expected< Type, std::string > morph::ui::detail::ScopeResolver::control ( ExprKind form,
std::string_view name ) const
inlinenodiscardoverridevirtual

Resolves a query or mutation name.

Parameters
formThe form.
nameThe name.
Returns
The type, or why it does not resolve.

Implements morph::ui::NameResolver.

Definition at line 3753 of file document.hpp.

◆ pref()

std::expected< Type, std::string > morph::ui::detail::ScopeResolver::pref ( std::string_view point,
std::span< std::string const > path ) const
inlinenodiscardoverridevirtual

Resolves a customization point.

Parameters
pointThe point.
pathThe rest.
Returns
The type, or why it does not resolve.

Implements morph::ui::NameResolver.

Definition at line 3778 of file document.hpp.


The documentation for this class was generated from the following file: