code: public IUserLayoutManager getUserLayoutManager(IPerson person, IUserProfile profile)
              throws PortalException {
          final IUserLayoutManager userLayoutManager =
                  (IUserLayoutManager)
                          this.beanFactory.getBean(
                                  USER_LAYOUT_MANAGER_PROTOTYPE_BEAN_NAME, person, profile);
  
          if (person.isGuest()) {
              return new ImmutableTransientUserLayoutManagerWrapper(userLayoutManager);
          }
          return new TransientUserLayoutManagerWrapper(userLayoutManager);
      }
docs: Obtain a regular user layout manager implementation (which allows transient layout
  alterations). The specific layout type depends on whether the user is a guest user.
  
  @return an <code>IUserLayoutManager</code> value