private function transformValue ($name, $attribute, &$exclude)
	{
		
		// If an attribute can accept NULL and it's value is '' then NULL will be set

		$value	= $this->iget ($name);

		if (is_null ($value) || (isset ($attribute['null']) && $attribute['null'] && $value === ''))
		{
			$this->iset ($name, NULL);
			$value		= 'NULL';
			$exclude[]	= $name;
		}
		else
		{
			
			// Switch special values
			
			switch ((string)$value)
			{

				case "CURRENT_TIMESTAMP":

					$value		= 'CURRENT_TIMESTAMP';
					$exclude[]	= $name;
					break;

				case 'CURRENT_UTC_DATE':

					$value		= "'" . $this->parser->utcDate () . "'";
					$exclude[]	= $name;
					break;

				default:

					$value	= ':' . $name;
					break;

			}

		}
		
		// Return transformed value
		
		return $value;
		
	}
private function transformValue ($name, $attribute, &$exclude)
	{
		
		// If an attribute can accept NULL and it's value is '' then NULL will be set

		$value	= $this->iget ($name);

		if (is_null ($value) || (isset ($attribute['null']) && $attribute['null'] && $value === ''))
		{
			$this->iset ($name, NULL);
			$value		= 'NULL';
			$exclude[]	= $name;
		}
		else
		{
			
			// Switch special values
			
			switch ((string)$value)
			{

				case "CURRENT_TIMESTAMP":

					$value		= 'CURRENT_TIMESTAMP';
					$exclude[]	= $name;
					break;

				case 'CURRENT_UTC_DATE':

					$value		= "'" . $this->parser->utcDate () . "'";
					$exclude[]	= $name;
					break;

				default:

					$value	= ':' . $name;
					break;

			}

		}
		
		// Return transformed value
		
		return $value;
		
	}
private function transformValue ( $ name , $ attribute , & $ exclude ) { // If an attribute can accept NULL and it's value is '' then NULL will be set $ value = $ this -> iget ( $ name ) ; if ( is_null ( $ value ) || ( isset ( $ attribute [ 'null' ] ) && $ attribute [ 'null' ] && $ value === '' ) ) { $ this -> iset ( $ name , NULL ) ; $ value = 'NULL' ; $ exclude [ ] = $ name ; } else { // Switch special values switch ( ( string ) $ value ) { case "CURRENT_TIMESTAMP" : $ value = 'CURRENT_TIMESTAMP' ; $ exclude [ ] = $ name ; break ; case 'CURRENT_UTC_DATE' : $ value = "'" . $ this -> parser -> utcDate ( ) . "'" ; $ exclude [ ] = $ name ; break ; default : $ value = ':' . $ name ; break ; } } // Return transformed value return $ value ; }
Apply any attribute value transformations for SQL query
@param string $name Attribute name
@param array $attribute Attribute property array
@param array $exclude Attribute exclusion array
@return mixed
Apply any attribute value transformations for SQL query