BooleanSanitizerUtil Class Reference

Inheritance diagram for BooleanSanitizerUtil:
SanitizerUtil

Static Public Member Functions

static getSqlAttributeValueDataAnalyzerType ()
static getBatchAttributeValueDataAnalyzerType ()
static getAcceptableValuesResolvingValues ()
static getAcceptableValues ()
static getLinkedMappingRuleType ()
static sanitizeValue ($modelClassName, $attributeName, $value, $mappingRuleData)

Detailed Description

Sanitizer for boolean type attributes.

Definition at line 30 of file BooleanSanitizerUtil.php.


Member Function Documentation

static getSqlAttributeValueDataAnalyzerType (  )  [static]
Returns:
string - the type of sql attribute value data analyzer or null if none available.

Reimplemented from SanitizerUtil.

Definition at line 32 of file BooleanSanitizerUtil.php.

static getBatchAttributeValueDataAnalyzerType (  )  [static]
Returns:
string - the type of batch attribute value data analyzer or null if none available.

Reimplemented from SanitizerUtil.

Definition at line 37 of file BooleanSanitizerUtil.php.

static getAcceptableValuesResolvingValues (  )  [static]

THE KEYS MUST MATCH THE KEYS IN getAcceptableValues() to have the correct mapping This method and getAcceptableValues() to be split because of some type casting issues in php where the keys were getting turned into integers instead of remaining as strings. Lowercase array of mappable boolean values. These values if found in an import, will be converted correctly to false/true. All other values are not valid.

See also:
getAcceptableValues()

Definition at line 50 of file BooleanSanitizerUtil.php.

static getAcceptableValues (  )  [static]

THE KEYS MUST MATCH THE KEYS IN getAcceptableValuesResolvingValues() to have the correct mapping This method and getAcceptableValuesResolvingValue() needed to be split because of some type casting issues in php where the keys were getting turned into integers instead of remaining as strings.

See also:
getAcceptableValuesResolvingValues()

Definition at line 71 of file BooleanSanitizerUtil.php.

static getLinkedMappingRuleType (  )  [static]
Returns:
string - the type of linked mapping rule or null if none available. Some sanitizers and data analyzers need information from a mapping rule form in order to perform their job. This method returns the type of mapping rule form.

Reimplemented from SanitizerUtil.

Definition at line 86 of file BooleanSanitizerUtil.php.

static sanitizeValue ( modelClassName,
attributeName,
value,
mappingRuleData 
) [static]

Given a value, attempt to convert the value to either true/false based on a mapping array of possible boolean values. If the value is not present, attemp to utilize the default value specified. If the value presented is not a valid mapping value then a InvalidValueToSanitizeException will be thrown.

Parameters:
string $modelClassName
string $attributeName
mixed $value
array $mappingRuleData

Reimplemented from SanitizerUtil.

Definition at line 101 of file BooleanSanitizerUtil.php.


The documentation for this class was generated from the following file:
 All Data Structures Functions Variables
Generated on Tue May 21 01:25:11 2013