private void addAndPrepareControlledObject ( Authorizable controlledObject ) { controlledObjects . add ( new WeakReference < Authorizable > ( controlledObject ) ) ; // Properly configure the new object boolean authorize = shouldAuthorize ( getLastAuthentication ( ) , controlledObject ) ; updateControlledObject ( controlledObject , authorize ) ; }
Add a new object to the list of controlled objects . Install our last known authorization decision so newly created objects will reflect the current security state .