[
https://issues.apache.org/jira/browse/WICKET-7142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18012665#comment-18012665
]
ASF subversion and git services commented on WICKET-7142:
---------------------------------------------------------
Commit 553ceb3c8dc425ef42b6a30bc16c17106cb61ff7 in wicket's branch
refs/heads/wicket-9.x from reiern70
[ https://gitbox.apache.org/repos/asf?p=wicket.git;h=553ceb3c8d ]
[WICKET-7142] make getComponent() public
(cherry picked from commit b10be0d2c222c269e6158f838cd0ddebebfbabbe)
> Allow public access for AbstractAjaxBehavior#getComponent()
> -----------------------------------------------------------
>
> Key: WICKET-7142
> URL: https://issues.apache.org/jira/browse/WICKET-7142
> Project: Wicket
> Issue Type: Wish
> Components: wicket-core
> Affects Versions: 9.19.0, 10.3.0
> Reporter: Patrick Davids
> Assignee: Ernesto Reinaldo Barreiro
> Priority: Major
> Fix For: 10.7.0
>
>
> Hi Wicket Team,
>
> in order to modify all AjaxRequest using an
> {color:#000000}AjaxRequestTarget{color}.{color:#000000}IListener
> impementation (updateAjaxAttributes()), registered with {color}
> (({color:#000000}WebApplication{color})
> application).getAjaxRequestTargetListeners().add(IListener), we need public
> access to AbstractAjaxBehavior#getComponent().
>
> example:
>
> {code:java}
> ((WebApplication) application).getAjaxRequestTargetListeners().add(new
> AjaxRequestTarget.IListener(){
> @Override
> public void updateAjaxAttributes(AbstractDefaultAjaxBehavior behavior,
> AjaxRequestAttributes attributes) {
> behavior.getComponent() // not accassible due to protected qualifier
> }
> });{code}
> Component is needed to due further tasks. Currently, we implemented access by
> java reflection features with setAccessible(true), which is not available
> anymore in java17.
>
> kind regards
> Patrick
--
This message was sent by Atlassian Jira
(v8.20.10#820010)