original_string: function GrantAddPageToSite(Site $site)
      {
          //Dummy page for evaluation
          $page = new Page();
          $page->SetUserGroup($site->GetUserGroup());
          $siteRights = $site->GetUserGroupRights();
          if ($siteRights)
          {
              $page->SetUserGroupRights($siteRights->GetPageRights());
          }
          return $this->Grant(BackendAction::Create(), $page);
      }
code: function GrantAddPageToSite(Site $site)
      {
          //Dummy page for evaluation
          $page = new Page();
          $page->SetUserGroup($site->GetUserGroup());
          $siteRights = $site->GetUserGroupRights();
          if ($siteRights)
          {
              $page->SetUserGroupRights($siteRights->GetPageRights());
          }
          return $this->Grant(BackendAction::Create(), $page);
      }
code_tokens: function GrantAddPageToSite ( Site $ site ) { //Dummy page for evaluation $ page = new Page ( ) ; $ page -> SetUserGroup ( $ site -> GetUserGroup ( ) ) ; $ siteRights = $ site -> GetUserGroupRights ( ) ; if ( $ siteRights ) { $ page -> SetUserGroupRights ( $ siteRights -> GetPageRights ( ) ) ; } return $ this -> Grant ( BackendAction :: Create ( ) , $ page ) ; }
docstring: Grant evaluation for adding a page on top of the site
  @param Site $site The site
  @return GrantResult The result
docstring_tokens: Grant evaluation for adding a page on top of the site