Uploaded image for project: 'Hibernate ORM'
  1. Hibernate ORM
  2. HHH-5289

Remove unnecessary security checks in property accessors

    Details

    • Last commented by a user?:
      true

      Description

      Setting Method.setAccessible() and Field.setAccessible() to true helps to avoid security checks.
      Currently it is executed only for non-public class members.

      Code example from DirectPropertyAccessor:

      if ( !ReflectHelper.isPublic(theClass, method) )

      { method.setAccessible(true); }

      Using this call for public members as well will increase the reflection call performance.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: