Lumiera
0.pre.03
»edit your freedom«
|
#include "steam/mobject/session/scope-locator.hpp"
Singleton service establishing a link to relate any compound of nested placement scopes to the current session and the current focus for querying and exploring this structure.
While it is OK to use this service directly, clients usually would prefer to use QueryFocus as a frontend.
ScopeLocator is the access point both to the current query scope location (as maintained with the help of the QueryFocusStack) and allows to explore the current session data structures (building on a QueryResolver service exposed by the session).
Definition at line 66 of file scope-locator.hpp.
Public Member Functions | |
ScopePath & | currPath () |
establishes the current query focus location. More... | |
template<typename MO > | |
ScopeQuery< MO >::iterator | explore (Scope const &) |
use the contents-resolving facility exposed by the session to enumerate the contents (children) of the given scope | |
template<typename MO > | |
ScopeQuery< MO >::iterator | getRawPath (Scope const &) |
use the contents-resolving facility exposed by the session to discover the path up from the given scope to model root. More... | |
ScopeQuery< MObject >::iterator | getRawPath (Scope const &) |
lib::IterSource< const Scope >::iterator | locate (Scope const &target) |
navigate the current QueryFocus scope location. More... | |
ScopePath & | pushPath () |
push aside the current focus location and open a new ScopePath frame, to serve as current location until released | |
template<typename MO > | |
ScopeQuery< MO >::iterator | query (Scope const &) |
use the contents-resolving facility exposed by the session to discover depth-first any object within this scope | |
size_t | stackSize () const |
Static Public Attributes | |
static lib::Depend< ScopeLocator > | instance |
Storage holding the single ScopeLocator instance. | |
Friends | |
class | lib::DependencyFactory< ScopeLocator > |
Private Member Functions | |
lumiera::QueryResolver const & | theResolver () |
Private Attributes | |
std::unique_ptr< QueryFocusStack > | focusStack_ |
ScopePath & currPath | ( | ) |
establishes the current query focus location.
Relies on the state of the QueryFocusStack. If there is no current focus location, a new one is created, referring to the root Scope.
|
inline |
use the contents-resolving facility exposed by the session to discover the path up from the given scope to model root.
Definition at line 144 of file scope-locator.hpp.
IterSource< const Scope >::iterator locate | ( | Scope const & | scope | ) |
navigate the current QueryFocus scope location.
The resulting access path to the new location is chosen such as to be most closely related to the original location; this includes picking a timeline or meta-clip attachment most similar to the one used in the original path. So effectively you'll see things through the same "scoping perspective" as given by the original path, if possible to the new location given as parameter. use the contents-resolving facility exposed by the session
scope | the new target location to navigate |
|
private |
the one (and only) access point actually to link the system of Scope and QueryFocus to the current session, by delegating resolution of contents discovery queries to the PlacementIndex managed within the session
Definition at line 128 of file scope.cpp.
References SessionServiceExploreScope::getResolver().