API / Apache Wicket Interview questions
What is the purpose of PageParameters?
PageParameters is Wicket's typed container for the data carried in a URL — the equivalent of query string or path parameters, but wrapped in an API that avoids manual request-parsing.
It's passed into a bookmarkable page's constructor and offers typed accessors like get("term").toString() or get("page").toInt(), handling the parsing and letting the page code work with real Java types instead of raw strings pulled from a servlet request. Values can arrive as either named parameters (?term=wicket&page=2) or as indexed/positional segments when a page is mounted to a pattern like /search/${term}.
Because the same PageParameters object also flows into setResponsePage() calls and link construction, it's the mechanism that keeps a bookmarkable page's constructor, its mounted URL, and any links pointing to it all working from one consistent, typed representation of "what data does this URL need."
More Related questions...