File modules/util/exception/ValidationException.class.php

Last commit: Sun Mar 14 23:51:49 2021 +0100	Jan Dankert	Refactoring: Using the ValidationException where possible.
1 <?php 2 3 namespace util\exception; 4 use Exception; 5 6 class ValidationException extends UIException 7 { 8 public $fieldName; 9 10 // Die Exception neu definieren, damit die Mitteilung nicht optional ist 11 public function __construct($fieldName,$key='COMMON_VALIDATION_ERROR',$params = [] ) 12 { 13 $this->fieldName = $fieldName; 14 15 // sicherstellen, dass alles korrekt zugewiesen wird 16 parent::__construct($key, '', $params ); 17 } 18 19 // maßgeschneiderte Stringdarstellung des Objektes 20 public function __toString() 21 { 22 return __CLASS__ . ": " . $this->fieldName . ": '{$this->message}' in {$this->file}({$this->line})\n" 23 . "{$this->getTraceAsString()}\n"; 24 } 25 26 }
Download modules/util/exception/ValidationException.class.php
History Sun, 14 Mar 2021 23:51:49 +0100 Jan Dankert Refactoring: Using the ValidationException where possible. Thu, 10 Sep 2020 18:02:54 +0200 Jan Dankert The dispatcher is now able to call the action methods with parameters. Sat, 22 Feb 2020 23:58:02 +0100 Jan Dankert Refactoring: Namespacing for module 'util'. Thu, 16 Aug 2018 00:36:25 +0200 Jan Dankert Aufgeräumt: Veraltete Session-Funktionen entfernt, da Projekt,Sprache,Model nicht mehr in der Session gehalten werden.