/**
  * {@inheritDoc}
  */
 public function validate($value)
 {
     if (is_array($value)) {
         for ($i = 0, $count = count($value); $i < $count; ++$i) {
             if (!$this->validate($value[$i])) {
                 return false;
             }
         }
         return true;
     }
     $numericValidator = new NumericValidator();
     $numericValidator->setRule(new NumericRule());
     if (!$numericValidator->validate($value)) {
         return false;
     }
     $min = $this->rule->getMin();
     if (is_int($min)) {
         if ($value < $min) {
             $this->setMessage($this->rule->getMinMessage());
             return false;
         }
     }
     $max = $this->rule->getMax();
     if (is_int($max)) {
         if ($value > $max) {
             $this->setMessage($this->rule->getMaxMessage());
             return false;
         }
     }
     return true;
 }