Lines Matching defs:nonempty
112 * @param bool $nonempty Return $default if parameter is set but empty()
115 public function param($name, $default = null, $nonempty = false)
119 if ($nonempty && empty($value)) return $default;
142 * @param bool $nonempty Init with $default if parameter is set but empty()
145 public function &ref($name, $default = '', $nonempty = false)
147 if (!isset($this->access[$name]) || ($nonempty && empty($this->access[$name]))) {
159 * @param bool $nonempty Return $default if parameter is set but empty()
162 public function int($name, $default = 0, $nonempty = false)
168 if ($nonempty && empty($value)) return $default;
178 * @param bool $nonempty Return $default if parameter is set but empty()
181 public function str($name, $default = '', $nonempty = false)
186 if ($nonempty && empty($value)) return $default;
216 * Note: $nonempty is here for interface consistency and makes not much sense for booleans
220 * @param bool $nonempty Return $default if parameter is set but empty()
223 public function bool($name, $default = false, $nonempty = false)
229 if ($nonempty && empty($value)) return $default;
239 * @param bool $nonempty Return $default if parameter is set but empty()
242 public function arr($name, $default = [], $nonempty = false)
246 if ($nonempty && empty($this->access[$name])) return $default;