Skip to content

[Engine] WorldQuery ECS 읽기 facade 구현#69

Merged
learncold merged 2 commits into
mainfrom
feat/issue-9
Apr 3, 2026
Merged

[Engine] WorldQuery ECS 읽기 facade 구현#69
learncold merged 2 commits into
mainfrom
feat/issue-9

Conversation

@SilverSupplier
Copy link
Copy Markdown
Collaborator

Summary

  • EcsCore에 대한 읽기 전용 facade WorldQuery 구현: view<T...>(), contains<T>(), get<T>() (const/non-const 오버로드)
  • EntityRegistry::eachAlive() 추가: 살아있는 entity와 Signature를 한 번에 순회하는 템플릿 메서드
  • WorldQueryTests 추가: view 필터링, 미등록 타입, 파괴된 entity 제외, contains, get 검증 (5개)
  • CMakeLists.txtWorldQuery.h, WorldQueryTests.cpp 등록

Related Issue

Area

  • Engine
  • Domain
  • Application
  • Docs
  • Build
  • Analysis
  • Chore

Architecture Check

  • I kept the dependency direction application -> domain -> engine.
  • I did not add Qt UI code to src/domain.
  • I did not add domain or application dependencies to src/engine.
  • I used src/ as the include root.

Verification

  • cmake --preset windows-debug
  • cmake --build --preset build-debug
  • ctest --preset test-debug
  • Not run (reason below)

Risks / Follow-up

  • get<T>() non-const 오버로드로 WorldQuery를 통한 컴포넌트 데이터 수정 가능 — entity/component 생명주기 변경은 EcsCore에서만 가능해 구조적 안전성 유지
  • EntityRegistry::eachAlive()view<T...>() 구현에 필요한 최소 지원 메서드로 Task-Implement generation-safe Entity handle and EntityRegistry #6 범위를 소폭 확장

SilverSupplier and others added 2 commits April 3, 2026 23:48
- WorldQuery: view<T...>(), contains<T>(), get<T>() read-only facade 추가
- EntityRegistry: eachAlive() 템플릿 순회 메서드 추가
- WorldQueryTests: view 필터링, 미등록 타입, 파괴된 entity, contains, get 검증 5개 테스트 추가
- CMakeLists.txt: WorldQuery.h, WorldQueryTests.cpp 등록

Closes #9

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@learncold learncold self-requested a review as a code owner April 3, 2026 16:54
@learncold learncold merged commit 5314fe1 into main Apr 3, 2026
2 checks passed
@learncold learncold deleted the feat/issue-9 branch April 3, 2026 16:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Task-Implement WorldQuery facade for ECS reads

2 participants