A module that allows the creation of “problems” with Template strings, and exposes a submodule
Query to turn those problems into query results.
To use this module, create a predicate that matches Locatable elements to Templates, and
use that query to instantiate this module.
predicate problem(Locatable elem, Template msg) {
msg = tpl("Variable named {var}").text("var", elem.(Variable).getName())
}
// Create a query for these elements with the above template:
import Problem<problem/2>::Query
// or, import the `Problem` class directly (for query reusability):
import Problem<problem/2>
Import path
import qtil.format.QLFormatClasses
| Problem | A problem class containing the results identified by the |
Modules
| Query | A module that selects the |
Aliases
| OptionalLocation | A class representing a placeholder location that may or may not exist. |
Parameters
| problem | pred |