public static function escape( $value, $escapeNull = true )
    {

        if( $value === null ) {
            return $escapeNull ? self::ESCAPE_CHARACTER . self::NULL_CHARACTER : '';
        }

        $value = str_replace( self::ESCAPE_CHARACTER, self::ESCAPE_CHARACTER . self::ESCAPE_CHARACTER, $value );
        $value = str_replace( self::RANGE_SEPARATOR, self::ESCAPE_CHARACTER . self::RANGE_SEPARATOR, $value );
        $value = str_replace( self::INTERVAL_SEPARATOR, self::ESCAPE_CHARACTER . self::INTERVAL_SEPARATOR, $value );

        return $value;

    }
public static function escape( $value, $escapeNull = true )
    {

        if( $value === null ) {
            return $escapeNull ? self::ESCAPE_CHARACTER . self::NULL_CHARACTER : '';
        }

        $value = str_replace( self::ESCAPE_CHARACTER, self::ESCAPE_CHARACTER . self::ESCAPE_CHARACTER, $value );
        $value = str_replace( self::RANGE_SEPARATOR, self::ESCAPE_CHARACTER . self::RANGE_SEPARATOR, $value );
        $value = str_replace( self::INTERVAL_SEPARATOR, self::ESCAPE_CHARACTER . self::INTERVAL_SEPARATOR, $value );

        return $value;

    }
public static function escape ( $ value , $ escapeNull = true ) { if ( $ value === null ) { return $ escapeNull ? self :: ESCAPE_CHARACTER . self :: NULL_CHARACTER : '' ; } $ value = str_replace ( self :: ESCAPE_CHARACTER , self :: ESCAPE_CHARACTER . self :: ESCAPE_CHARACTER , $ value ) ; $ value = str_replace ( self :: RANGE_SEPARATOR , self :: ESCAPE_CHARACTER . self :: RANGE_SEPARATOR , $ value ) ; $ value = str_replace ( self :: INTERVAL_SEPARATOR , self :: ESCAPE_CHARACTER . self :: INTERVAL_SEPARATOR , $ value ) ; return $ value ; }
Escape a interval fragments
@param scalar $value
@return string
Escape a interval fragments