bevy/crates/bevy_ecs/src/query
Sélène Amanita ca81d3e435
Document query errors (#8692)
# Objective

Add documentation to `Query` and `QueryState` errors in bevy_ecs
(`QuerySingleError`, `QueryEntityError`, `QueryComponentError`)

## Solution

- Change display message for `QueryEntityError::QueryDoesNotMatch`: this
error can also happen when the entity has a component which is filtered
out (with `Without<C>`)
- Fix wrong reference in the documentation of `Query::get_component` and
`Query::get_component_mut` from `QueryEntityError` to
`QueryComponentError`
- Complete the documentation of the three error enum variants.
- Add examples for `QueryComponentError::MissingReadAccess` and
`QueryComponentError::MissingWriteAccess`
- Add reference to `QueryState` in `QueryEntityError`'s documentation.

---

## Migration Guide

Expect `QueryEntityError::QueryDoesNotMatch`'s display message to
change? Not sure that counts.

---------

Co-authored-by: harudagondi <giogdeasis@gmail.com>
2023-05-30 14:41:14 +00:00
..
access.rs Fixed several missing links in docs. (#8117) 2023-04-23 17:28:36 +00:00
fetch.rs Fix 1.69 CI clippy lints (#8450) 2023-04-20 16:51:21 +00:00
filter.rs Fix 1.69 CI clippy lints (#8450) 2023-04-20 16:51:21 +00:00
iter.rs Increase type safety and clarity for change detection (#7905) 2023-03-09 17:17:02 +00:00
mod.rs Pass query change ticks to QueryParIter instead of always using change ticks from World. (#8029) 2023-03-13 22:06:16 +00:00
par_iter.rs Pass query change ticks to QueryParIter instead of always using change ticks from World. (#8029) 2023-03-13 22:06:16 +00:00
state.rs Document query errors (#8692) 2023-05-30 14:41:14 +00:00