Skip to content

feat: add RouteHierarchy walker#24446

Draft
web-padawan wants to merge 1 commit into
feat/route-parent-annotationfrom
feat/route-hierarchy-walker
Draft

feat: add RouteHierarchy walker#24446
web-padawan wants to merge 1 commit into
feat/route-parent-annotationfrom
feat/route-hierarchy-walker

Conversation

@web-padawan
Copy link
Copy Markdown
Member

Summary

Adds com.vaadin.flow.router.RouteHierarchy — walks ancestor routes
for a given @route class, consulting @RouteParent first and falling
back to URL-prefix walking. Cycle-safe.

Stacked on #24444 (adds @RouteParent). That PR should land first;
GitHub will auto-retarget this PR to main once it merges.

Test plan

  • mvn -pl flow-server test -Dtest=RouteHierarchyTest (14 cases)
  • Reviewer sanity-checks the algorithm against the breadcrumbs
    flow-spec.md Step 3 contract

🤖 Generated with Claude Code

Introduces com.vaadin.flow.router.RouteHierarchy with resolveAncestors
and resolveParent. Consumes @RouteParent first, falls back to
URL-prefix walking via RouteConfiguration#getTemplate /
#getRoute. Cycle-safe via a visited set.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@sonarqubecloud
Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants