Prior to this commit, the `BeanRegistrationsAotContribution` would only contribute introspection hints for declared methods. This does not cover inherited public methods. This commit adds the missing hint on public methods. Fixes gh-31293
Prior to this commit, the `BeanRegistrationsAotContribution` would only contribute introspection hints for declared methods. This does not cover inherited public methods. This commit adds the missing hint on public methods. Fixes gh-31293