Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Merged by Bors] - Improve WorldQuery docs #5740

Closed
wants to merge 25 commits into from

Conversation

Nilirad
Copy link
Contributor

@Nilirad Nilirad commented Aug 19, 2022

Objective

  • Update docs to WorldQuery

Solution

Nilirad and others added 24 commits August 19, 2022 12:33
Co-authored-by: Alice Cecile <alice.i.cecile@gmail.com>
Co-authored-by: MinerSebas <66798382+MinerSebas@users.noreply.github.com>
Co-authored-by: James Liu <contact@jamessliu.com>
This will reflect the added context in this PR
that is aware of what query items are
and that they can be read-only or not.
Moved all links to the bottom of the doc comment.
Links have been alphabetically ordered.

Rebase notes:

- After bevyengine#5205 got merged,
  the “Safety” section of `WorldQuery` has changed.
  I listed the mentioned methods for a better layout.
  I also removed the `WorldQuery::` prefix for readability.
- I don't have enough knowledge of the previous and current state of `WorldQuery` types,
  so the documentation may be outdated somewhere.
  `WorldQuery` needs another review round.
Co-authored-by: Rob Parrett <robparrett@gmail.com>
Co-authored-by: Boxy <supbscripter@gmail.com>
@Nilirad Nilirad mentioned this pull request Aug 19, 2022
2 tasks
crates/bevy_ecs/src/query/fetch.rs Outdated Show resolved Hide resolved
crates/bevy_ecs/src/query/fetch.rs Outdated Show resolved Hide resolved
crates/bevy_ecs/src/query/fetch.rs Outdated Show resolved Hide resolved
Co-authored-by: Afonso Lage <lage.afonso@gmail.com>
@Nilirad Nilirad added C-Docs An addition or correction to our documentation A-ECS Entities, components, systems, and events labels Aug 19, 2022
crates/bevy_ecs/src/query/fetch.rs Show resolved Hide resolved
@Weibye Weibye added the S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it label Aug 27, 2022
///
/// There are many types that natively implement this trait:
///
/// - **Component references.**
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// - **Component references.**
/// - **Component references (`&T` and `&mut T`).**

Just to make it crystal clear what "Component references" mean.

/// [`With`] and [`Without`] filters can be applied to check if the queried entity contains or not a particular component.
/// - **Change detection filters.**
/// [`Added`] and [`Changed`] filters can be applied to detect component changes to an entity.
/// - **Filter disjunction operator.**
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// - **Filter disjunction operator.**
/// - **[Filter disjunction operator](Or).**

Might as well link directly to it from the start.

@alice-i-cecile
Copy link
Member

bors r+

bors bot pushed a commit that referenced this pull request Sep 2, 2022
# Objective

- Update docs to `WorldQuery`

## Solution

- See #4989. This PR is derived from it, and limited to the `WorldQuery` item docs.
@bors bors bot changed the title Improve WorldQuery docs [Merged by Bors] - Improve WorldQuery docs Sep 2, 2022
@bors bors bot closed this Sep 2, 2022
james7132 pushed a commit to james7132/bevy that referenced this pull request Oct 28, 2022
# Objective

- Update docs to `WorldQuery`

## Solution

- See bevyengine#4989. This PR is derived from it, and limited to the `WorldQuery` item docs.
ItsDoot pushed a commit to ItsDoot/bevy that referenced this pull request Feb 1, 2023
# Objective

- Update docs to `WorldQuery`

## Solution

- See bevyengine#4989. This PR is derived from it, and limited to the `WorldQuery` item docs.
@Nilirad Nilirad deleted the WorldQuery branch December 5, 2023 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-ECS Entities, components, systems, and events C-Docs An addition or correction to our documentation S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants