@@ -30,7 +30,7 @@ |
||
| 30 | 30 | |
| 31 | 31 | /** |
| 32 | 32 | * |
| 33 | - * @param type $id |
|
| 33 | + * @param string $id |
|
| 34 | 34 | * @param type $pattern Regex pattern without anchors (example: [a-z]+) |
| 35 | 35 | * @param type $message |
| 36 | 36 | */ |
@@ -34,6 +34,9 @@ |
||
| 34 | 34 | $this->getControlElement()->setAttribute('required', (boolean) $required); |
| 35 | 35 | } |
| 36 | 36 | |
| 37 | + /** |
|
| 38 | + * @param string $pattern |
|
| 39 | + */ |
|
| 37 | 40 | public function setPattern($pattern, $message = null) { |
| 38 | 41 | $this->addValidityCheck(new CheckPattern('pattern', $pattern, $message)); |
| 39 | 42 | $this->getControlElement()->setAttribute('pattern', $pattern); |