Checks if the value of the element is greater than the given value
@param string $name Name of the element to filter
@param  array $options Keys may include [message]
@return boolean
356148
public function greaterThan(array $options) {
        if (isset($options['element'])) {
            if (isset($this->data[$options['element']])) {
                $than = ' "' . $this->cleanElement($options['element']) . '"';
                if ($this->elementData > $this->data[$options['element']] || (empty($this->elementData) && $this->elementData !== 0)) {
                    return true;
                }
            }
        } else if (isset($options['value'])) {
            $than = $options['value'];
            if ($this->elementData > $options['value']) {
                return true;
            }
        }

        $this->addError($this->checkMessage('Value must be greater than ' . $than, $options));
        return false;
    }
1355721
public function getValue($name)
    {
		foreach($this->elements as $element){
			if($element->getName() == $name){
				return  $element->getEvaluatedValue();
			}
		}

        return false;
    }
621842
public function set_options($name,$options){
		if (is_array($options)){
			$str="";
			foreach($options as $k => $v)
				$str.="<item value='".$this->xmlentities($k)."' label='".$this->xmlentities($v)."' />";
			$options=$str;
		}
		$this->options[$name]=$options;
	}
279480
public function getCheckbox($name, array $options=[]) {
		$choices = $this->getChoices();
		$default = $this->value;

		$value = isset($options['value']) ? $options['value']:null;
		if($value===null) {
			foreach($choices as $k=>$v) {
				if($v == $name) {
					$value = $k;
					break;
				}
			}
		}
		if($value === null)
			throw new \Exception('No value for checkbox '.$name);

		if(in_array($value, $default))
			$options['attrs']['checked'] = 'checked';
		$options['label'] = $name;

		return $this->getTopForm()->getWidget('checkbox', $this->name.'[]', $value, $options);
	}
250419
public function getLimit($name)
    {
        if (isset($this->limits[$name])) {
            return $this->limits[$name];
        }

        return false;
    }
546458
public static function isEnabled(array $options, string $name, $default = false): bool
    {
        $enabled = $default;
        $options = self::normalize($options);

        if (array_key_exists('*', $options)) {
            $enabled = $options['*'];
        }

        if (array_key_exists($name, $options)) {
            $enabled = (bool) $options[$name];
        }

        return $enabled;
    }
1049713
public function hasFilter($name)
    {
        foreach ($this->filters as $filter) {
            if ($filter->getFieldName() === $name) {
                return true;
            }
        }
    
        return false;
    }
258812
private function optionHasArgument($name)
    {
        foreach ($this->optionList as $option) {
            if ($option->matches($name)) {
                return $option->mode() != Getopt::NO_ARGUMENT;
            }
        }
        return false;
    }
184907
private function filterParams($name)
    {
        if (empty($this->options[$name])) {
            return;
        }

        if (is_array($this->options['params_filters'])) {
            foreach ($this->options['params_filters'] as $pattern) {
                foreach ($this->options[$name] as $key => $value) {

                    if (preg_match($pattern, $key)) {
                        $this->options[$name][$key] = '[FILTERED]';
                    }
                }
            }
        }
    }
1344233
public function group($Name, $Options = null)
    {
    
        if (!$Name) {
            throw $this->newException('You must specify a label for the group!');
        }
        
        if ($Options) {
            if (!is_array($Options)) {
                throw $this->newException('Options must be defined as an array!');
            }
            if (array_key_exists('Collapsed', $Options)) {
                $Options['Collapsed'] = ($Options['Collapsed'])?'true':'false';
            }
        }
        
        return $this->fb(null, $Name, FirePHP::GROUP_START, $Options);
    }
821618
public function minLength(array $options) {
        if ($options['value'] && strlen($this->elementData) >= $options['value'])
            return true;

        $this->addError($this->checkMessage('Length must not be less than ' . $options['value'], $options));
        return false;
    }
23554
public function input($name, $options = array())
    {
        $options += array(
            "type"  => "text",
            "id"    => $this->id($name),
            "name"  => $this->name($name),
            "error" => true,
            "class" => "",
            "value" => "",
            "label" => null
        );

        $currentValue = $this->getCurrentValue($options['name']);

        $errorHtml = "";
        $fieldHasErrors = false;

        if (!is_null($this->associatedEntity)) {
            // Checkboxes may be posted has data[name][0] and therefore
            // we need to remove it to get the absolute field name.
            $validationName = $options["type"] === "checkbox" ?
                preg_replace('/\[\d+\]$/', '', $name) :
                $name;

            if ($this->associatedEntity->hasErrors($validationName)) {
                if ((bool)$options['error']) {
                    $errorHtml = $this->generateInlineErrors($validationName);
                }
                $fieldHasErrors = true;
                $options['class'] .= " error ";
            }
        }
        unset($options["error"]);

        $label = "";
        if (!is_null($options['label'])) {
            $labelOptions = array(
                "for"    => $options["id"],
                "class" => $fieldHasErrors ? "error" : "",
                "label" => $options["label"],
            );

            $label .= $this->label($options['name'], $labelOptions);
        }
        unset($options['label']);

        switch (strtolower($options['type'])) {
            case "textarea":
                return $label . "\n" . $this->generateTextarea($options, $currentValue) . $errorHtml . "\n";
            case "select":
                return $label . "\n" . $this->generateSelect($options, $currentValue) . $errorHtml . "\n";
            case "radio":
                return $this->generateRadio($options, $currentValue) . $errorHtml . "\n" . $label . "\n";
            case "checkbox":
                return $this->generateCheckbox($options, $currentValue) . $errorHtml . "\n" . $label . "\n";
            case "hidden":
                return $label . "\n" . $this->generateHidden($options, $currentValue) . $errorHtml . "\n";
            default:
                return $label . "\n" . $this->generateTextinput($options, $currentValue) . $errorHtml . "\n";
        }
    }
109062
protected function max($name, $value, $max){
        //Si no se completo no se valida
        if(! $this->isComplete($value)){
            return TRUE;
        }
        if(is_numeric($value)){
            $value= (float)$value;
            if($value > $max){
                $this->add_message($name, 'max', array('max' => $max));
                return FALSE;
            }
        }else{
            $this->add_message($name, 'is_integer');
            return FALSE;
        }
        return TRUE;
    }
380366
public function filter($name, array $options = [])
    {
        if (static::EXT_FILTER === parent::filter($name, $options) and isset($this->filters[$name])) {
            $filter = new $this->filters[$name]($this, $options);
            $filter->run();
        }
    }
614029
public function lessThan(array $options) {
        if (isset($options['element'])) {
            if (isset($this->data[$options['element']])) {
                $than = ' "' . $this->cleanElement($options['element']) . '"';
                if ($this->elementData < $this->data[$options['element']]) {
                    return true;
                }
            }
        } else if (isset($options['value'])) {
            $than = $options['value'];
            if ($this->elementData < $options['value']) {
                return true;
            }
        }

        $this->addError($this->checkMessage('Value must be less than ' . $than, $options));
        return false;
    }
659647
public function hasElement($name)
    {
        foreach($this->elements as $element){
            if($element->getName() == $name) {
                return true;
            }
        }

        return false;
    }
1276821
public function hasOption($name) {
        return $this->definition->hasOption($name) && isset($this->options[$name]);
    }