phpDocumentor Rewrite
PHPUnit
[ class tree: Rewrite ] [ index: Rewrite ] [ all elements ]

Class: AdminRewriteMockParser

Source Location: /modules/rewrite/test/phpunit/AdminRewriteControllerTest.class

Class AdminRewriteMockParser

Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From RewriteParser

RewriteParser::$_parserId
RewriteParser::$_type
RewriteParser::$_urlGeneratorId

Inherited From RewriteParser

RewriteParser::fetchEmbedConfig()
RewriteParser::getErrorMessage()
Returns translated error message, called from AdminRewrite when an unsucsessful save has been made. A valid $code is anything that $this->saveActiveRules would return if an error occurs.
RewriteParser::getParserId()
RewriteParser::getParserType()
RewriteParser::getUrlGeneratorId()
RewriteParser::handleAdminParserRequest()
Handles the submitted form and should save the settings.
RewriteParser::handleTestResultsRequest()
Handles the submitted form and should save any settings (ie. forced tests).
RewriteParser::isValidRule()
This function is called when new rules are saved and by rewrite.AdminRewrite to know if this rule should be displayed. If the parser overrides this function it needs to call this (the parent). It also verifies that locked rules are saved with the original pattern. We perform a sanity check to minimize possible conflicts and bad regular expressions.
RewriteParser::loadAdminParserTemplate()
Displays the parser configuration if the template variable $AdminParser.body is set. It should be a Gallery base dir relative path.
RewriteParser::loadTestResultsTemplate()
Displays the test results if the template variable $TestResults.body is set. It should be a Gallery base dir relative path.
RewriteParser::needsConfiguration()
By default there's nothing to configure, so we return success.
RewriteParser::needsEmbedConfig()
RewriteParser::saveAccessList()
Saves list of hosts Gallery allows as referrer and if Gallery should allow an empty referrer.
RewriteParser::saveActiveRules()
Saves the active rewrite rules. This needs to be implemented by the specific plugin. It needs to save two rewrite params, activeRules and shortUrls. activeRules is just a serialized array of the given activeRules and shortUrls is returned by RewriteHelper::parseActiveRules(). It returns REWRITE_STATUS_OK on success.
RewriteParser::saveEmbedConfig()
RewriteParser::_setParserId()
RewriteParser::_setParserType()
RewriteParser::_setUrlGeneratorId()

[ Top ]
Method Summary
AdminRewriteMockParser   AdminRewriteMockParser()  
void   handleAdminParserRequest()  
void   handleTestResultsRequest()  
void   isValidRule()  
void   saveAccessList()  
void   saveActiveRules()  

[ Top ]
Methods
Constructor AdminRewriteMockParser  [line 502]

  AdminRewriteMockParser AdminRewriteMockParser( )



[ Top ]
handleAdminParserRequest  [line 532]

  void handleAdminParserRequest( $form  )

Parameters:
   $form: 


Redefinition of:
RewriteParser::handleAdminParserRequest()
Handles the submitted form and should save the settings.

[ Top ]
handleTestResultsRequest  [line 520]

  void handleTestResultsRequest( $form  )

Parameters:
   $form: 


Redefinition of:
RewriteParser::handleTestResultsRequest()
Handles the submitted form and should save any settings (ie. forced tests).

[ Top ]
isValidRule  [line 507]

  void isValidRule( $rule, [ $pattern = null]  )

Parameters:
   $rule: 
   $pattern: 


Redefinition of:
RewriteParser::isValidRule()
This function is called when new rules are saved and by rewrite.AdminRewrite to know if this rule should be displayed. If the parser overrides this function it needs to call this (the parent). It also verifies that locked rules are saved with the original pattern. We perform a sanity check to minimize possible conflicts and bad regular expressions.

[ Top ]
saveAccessList  [line 582]

  void saveAccessList( $accessList, $allowEmptyReferer  )

Parameters:
   $accessList: 
   $allowEmptyReferer: 


Redefinition of:
RewriteParser::saveAccessList()
Saves list of hosts Gallery allows as referrer and if Gallery should allow an empty referrer.

[ Top ]
saveActiveRules  [line 544]

  void saveActiveRules( [ $activeRules = null], [ $rewriteModule = null]  )

Parameters:
   $activeRules: 
   $rewriteModule: 


Redefinition of:
RewriteParser::saveActiveRules()
Saves the active rewrite rules. This needs to be implemented by the specific plugin. It needs to save two rewrite params, activeRules and shortUrls. activeRules is just a serialized array of the given activeRules and shortUrls is returned by RewriteHelper::parseActiveRules(). It returns REWRITE_STATUS_OK on success.

[ Top ]

Documentation generated on Fri, 08 Oct 2010 04:36:55 -0700 by phpDocumentor 1.3.0RC6