public function validate($field, $data = NULL, $flags = 0x000000) {
    $key = $this->getKey($field);
    
    if (isset($this->dataProvider)) {
      $data = $this->dataProvider->getValidatorData($field);
    }
    
    if ($this->hasField($field)) {
      
      try {
          
        foreach ($this->rules[$key] as $rule) {
          $data = $rule->validate($data); // wenn wir hier data zurückgeben, können wir die rules chainen
        }
        
      } catch (EmptyDataException $e) {
        if (($flags & self::OPTIONAL) == self::OPTIONAL || $this->isOptional($field)) {
          return $e->getDefaultValue();

        } else {
          if ($e->getMessage() == NULL) {
            $e->setMessage(sprintf($this->standardEmptyMessage,$this->getKey($field)));
          }

          throw $this->convertToValidatorException($e, $field, $data);
        }

      } catch (\Exception $e) {
        throw $this->convertToValidatorException($e, $field, $data);
      }
      
    } else {
      throw new \Psc\Exception('Feld: '.Code::varInfo($field).' ist dem Validator nicht bekannt.');
    }
    
    return $data;
  }