phpPeanuts  2.2.0
phpPeanuts framework
 All Data Structures Namespaces Files Functions Variables
Public Member Functions | Data Fields
PntAction Class Reference

Inherits PntRequestHandler.

Inherited by PntObjectDeleteAction, PntObjectDeleteMarkedAction, and PntObjectSaveAction.

Public Member Functions

 __construct ($whole, $requestData)
 
 beginTransaction ()
 
 commit ()
 
 rollBack ()
 
 finishAndRedirectToContext ($obj, $message)
 
 checkActionTicket ()
 
 checkRequestMethod ()
 
 rerouteErrorHandling ()
 
 restoreErrorHandling ()
 
 handleError ($level, $message, $filePath, $lineNumber)
 
- Public Member Functions inherited from PntRequestHandler
 __construct ($whole, $requestData)
 
 getDir ()
 
 getDomainDir ($type=null)
 
 getBaseUrl ()
 
 getConverter ()
 
 getDebugMode ()
 
 initForHandleRequest ()
 
 startSession ()
 
 getContextHref ($footprintId)
 
 getController ()
 
 getScout ()
 
 getGlobalFilters ()
 
 forwardRequest ($requestData, $information=null)
 
 redirectRequest ($requestData, $information=null, $dir=null)
 
 queryStringFrom ($requestData, $param=null)
 
 getRequestParam ($key)
 
 getReqParam ($key, $asHtml=false)
 
 htOut ($aString)
 
 getRequestHandler ($requestData, $dir=null)
 
 tryUseHandlerClass ($handlerClass, &$attempted)
 
 getHandlersTriedString ($attempted)
 
 __toString ()
 
 toString ()
 
 getLabel ()
 
 getName ()
 
 getThisPntHandlerName ()
 
 getInformation ()
 
 getEventualItemNotFoundMessage ()
 
 setInformation ($value)
 
 getTypeLabel ()
 
 getType ()
 
 checkAlphaNumeric ($value)
 
 getTryUseClassTryParams ($className, $dir)
 
 getIncludesDir ()
 
 tryUseClass ($className, $dir)
 
 useClass ($className, $dir)
 
 getTypeClassDescriptor ()
 
 getRequestedObject ()
 
 setRequestedObject ($value)
 
 getFormTexts ()
 
 getFormTextPaths ()
 
 setFormTexts ($value)
 
 getMarkedItemsCollector ()
 

Data Fields

 $inTransaction = false
 
- Data Fields inherited from PntRequestHandler
 $whole
 
 $information
 
 $controller
 
 $requestData
 
 $request
 

Constructor & Destructor Documentation

__construct (   $whole,
  $requestData 
)

Member Function Documentation

beginTransaction ( )
checkActionTicket ( )

To prevent Cross-site request forgery each form has a parameter pntActionTicket that will change each time the form is printed. It is stored in the session. When an action is invoked, the ticket is checked and removed from the session.

Returns
string null if OK, or errormessage if the pntRef is unknown or the ticket is no longer valid
Exceptions
PntValidationExceptionif no ticket, no pntRef or if pntRef is registered but ticket is not
checkRequestMethod ( )
commit ( )
finishAndRedirectToContext (   $obj,
  $message 
)
handleError (   $level,
  $message,
  $filePath,
  $lineNumber 
)
rerouteErrorHandling ( )

Route error handling over this. Exception handling is not rerouted, exceptions are cought PntErrorHandler now throws PntErrorException for fatal errors Warning: restoreErrorHandling is no longer called by default on the end of the transaction

restoreErrorHandling ( )
rollBack ( )
Exceptions
PntDbErrorif rollback fails

Field Documentation

$inTransaction = false

The documentation for this class was generated from the following file: