bevy/crates/bevy_ecs/src
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
..
entity Make scene handling of entity references robust (#7335) 2023-05-01 15:49:27 +00:00
query Document query errors (#8692) 2023-05-30 14:41:14 +00:00
schedule Improve safety for the multi-threaded executor using UnsafeWorldCell (#8292) 2023-05-29 15:22:10 +00:00
storage Fixed several missing links in docs. (#8117) 2023-04-23 17:28:36 +00:00
system Document query errors (#8692) 2023-05-30 14:41:14 +00:00
world Improve safety for the multi-threaded executor using UnsafeWorldCell (#8292) 2023-05-29 15:22:10 +00:00
archetype.rs Inline more ECS functions (#8083) 2023-04-12 19:52:06 +00:00
bundle.rs Inline more ECS functions (#8083) 2023-04-12 19:52:06 +00:00
change_detection.rs Fix a change detection test (#8605) 2023-05-16 01:41:24 +00:00
component.rs Inline more ECS functions (#8083) 2023-04-12 19:52:06 +00:00
event.rs Manually implement common traits for EventId (#8529) 2023-05-04 12:22:25 +00:00
lib.rs Fixed several missing links in docs. (#8117) 2023-04-23 17:28:36 +00:00
reflect.rs Rename map_entities and map_specific_entities (#7570) 2023-05-01 21:40:19 +00:00
removal_detection.rs Use UnsafeWorldCell to increase code quality for SystemParam (#8174) 2023-04-01 15:45:07 +00:00