[ Index ]

PHP Cross Reference of vtigercrm-6.1.0

title

Body

[close]

/libraries/htmlpurifier/library/HTMLPurifier/ -> VarParser.php (summary)

(no description)

File Size: 154 lines (5 kb)
Included or required: 1 time
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

HTMLPurifier_VarParser:: (6 methods):
  parse()
  parseImplementation()
  error()
  errorInconsistent()
  errorGeneric()
  getTypeName()


Class: HTMLPurifier_VarParser  - X-Ref

Parses string representations into their corresponding native PHP
variable type. The base implementation does a simple type-check.

parse($var, $type, $allow_null = false)   X-Ref
Validate a variable according to type. Throws
HTMLPurifier_VarParserException if invalid.
It may return NULL as a valid type if $allow_null is true.

param: $var Variable to validate
param: $type Type of variable, see HTMLPurifier_VarParser->types
param: $allow_null Whether or not to permit null as a value
return: Validated and type-coerced variable

parseImplementation($var, $type, $allow_null)   X-Ref
Actually implements the parsing. Base implementation is to not
do anything to $var. Subclasses should overload this!


error($msg)   X-Ref
Throws an exception.


errorInconsistent($class, $type)   X-Ref
Throws an inconsistency exception.


errorGeneric($var, $type)   X-Ref
Generic error for if a type didn't work.


getTypeName($type)   X-Ref
No description



Generated: Fri Nov 28 20:08:37 2014 Cross-referenced by PHPXref 0.7.1