|
ObjectivelyMVC
Object oriented MVC framework for SDL3 and GNU C
|
#include <assert.h>#include <stdlib.h>#include <string.h>#include <Objectively/Hash.h>#include <Objectively/Array.h>#include <Objectively/Set.h>#include "Log.h"#include "Selector.h"#include "View.h"Go to the source code of this file.
Data Structures | |
| struct | Match |
| A context for View matching. More... | |
| struct | Selection |
| A context for View selection. More... | |
Macros | |
| #define | _Class _Selector |
Functions | |
| static Set * | __select (View *view, Selection *selection) |
| Recursively selects Views by iterating the SelectorSequences in the given Selection. | |
| static void | __selectEnumerator (View *view, ident data) |
| ViewEnumerator adapter for __select, so it may be passed to the View::enumerate* family of methods, which require the exact ViewEnumerator signature. | |
| static bool | _matchesView (const View *view, Match *match) |
| Recursive View match predicate, invoked directly by matchesView and indirectly, via _matchesViewEnumerator, by the View::enumerate* methods. | |
| static void | _matchesViewEnumerator (View *view, ident data) |
| ViewEnumerator adapter for _matchesView, so it may be passed to the View::enumerate* family of methods, which require the exact ViewEnumerator signature. | |
| static Set * | _select (const Selector *self, View *view) |
| static void | _selectFirst (Selection *selection, View *view) |
| Recursively selects the first View by iterating the SelectorSequences in the given Selection. | |
| static void | _selectFirstEnumerator (View *view, ident data) |
| ViewEnumerator adapter for _selectFirst, so it may be passed to the View::enumerate* family of methods, which require the exact ViewEnumerator signature. Note that _selectFirst's parameter order (Selection *, View *) is reversed from ViewEnumerator's (View *, ident); this adapter restores the correct order rather than relying on an incompatible raw cast. | |
| Class * | _Selector (void) |
| static Order | compareTo (const Selector *self, const Selector *other) |
| static void | dealloc (Object *self) |
| static String * | description (const Object *self) |
| static void | enumerateSelection (const Selector *self, View *view, ViewEnumerator enumerator, ident data) |
| static int | hash (const Object *self) |
| static void | initialize (Class *clazz) |
| static Selector * | initWithRule (Selector *self, const char *rule) |
| static bool | isEqual (const Object *self, const Object *other) |
| static bool | matchesView (const Selector *self, const View *view) |
| static Array * | parse (const char *rules) |
| static View * | selectFirst (const Selector *self, View *view) |
| static int | specificity (const Selector *selector) |
| #define _Class _Selector |
Definition at line 36 of file Selector.c.
Recursively selects Views by iterating the SelectorSequences in the given Selection.
Definition at line 343 of file Selector.c.
|
static |
ViewEnumerator adapter for __select, so it may be passed to the View::enumerate* family of methods, which require the exact ViewEnumerator signature.
Definition at line 387 of file Selector.c.
Recursive View match predicate, invoked directly by matchesView and indirectly, via _matchesViewEnumerator, by the View::enumerate* methods.
Definition at line 227 of file Selector.c.
|
static |
ViewEnumerator adapter for _matchesView, so it may be passed to the View::enumerate* family of methods, which require the exact ViewEnumerator signature.
Definition at line 269 of file Selector.c.
Definition at line 395 of file Selector.c.
Recursively selects the first View by iterating the SelectorSequences in the given Selection.
Definition at line 417 of file Selector.c.
|
static |
ViewEnumerator adapter for _selectFirst, so it may be passed to the View::enumerate* family of methods, which require the exact ViewEnumerator signature. Note that _selectFirst's parameter order (Selection *, View *) is reversed from ViewEnumerator's (View *, ident); this adapter restores the correct order rather than relying on an incompatible raw cast.
Definition at line 459 of file Selector.c.
| Class * _Selector | ( | void | ) |
Definition at line 504 of file Selector.c.
Definition at line 151 of file Selector.c.
|
static |
Definition at line 43 of file Selector.c.
|
static |
Definition at line 56 of file Selector.c.
|
static |
Definition at line 168 of file Selector.c.
|
static |
Definition at line 66 of file Selector.c.
|
static |
Definition at line 484 of file Selector.c.
Definition at line 190 of file Selector.c.
|
static |
Definition at line 76 of file Selector.c.
Definition at line 277 of file Selector.c.
|
static |
Definition at line 291 of file Selector.c.
Definition at line 467 of file Selector.c.
|
static |
Definition at line 98 of file Selector.c.