src/Database/MySQL/String.php
public static function parse($object){
		
		$len = \strlen($object);
		
		if(Number::between($len, MySQL::getConstant('CHAR_LEN_MIN'),
				MySQL::getConstant('CHAR_LEN_MAX'))){
			return new static($len, static::CHAR);
		}
		else if(Number::between($len, MySQL::getConstant('VARCHAR_LEN_MIN'),
				MySQL::getConstant('VARCHAR_LEN_MAX'))){
			return new static($len, static::VARCHAR);
		}
		else if(Number::between($len, MySQL::getConstant('MEDIUMTEXT_LEN_MIN'),
				MySQL::getConstant('MEDIUMTEXT_LEN_MAX'))){
			return new static($len, static::MEDIUMTEXT);
		}
		else if(Number::between($len, MySQL::getConstant('LONGTEXT_LEN_MIN'),
				MySQL::getConstant('LONGTEXT_LEN_MAX'))){
			return new static($len, static::LONGTEXT);
		}
		
		return null;
		
	}
public static function parse($object){
		
		$len = \strlen($object);
		
		if(Number::between($len, MySQL::getConstant('CHAR_LEN_MIN'),
				MySQL::getConstant('CHAR_LEN_MAX'))){
			return new static($len, static::CHAR);
		}
		else if(Number::between($len, MySQL::getConstant('VARCHAR_LEN_MIN'),
				MySQL::getConstant('VARCHAR_LEN_MAX'))){
			return new static($len, static::VARCHAR);
		}
		else if(Number::between($len, MySQL::getConstant('MEDIUMTEXT_LEN_MIN'),
				MySQL::getConstant('MEDIUMTEXT_LEN_MAX'))){
			return new static($len, static::MEDIUMTEXT);
		}
		else if(Number::between($len, MySQL::getConstant('LONGTEXT_LEN_MIN'),
				MySQL::getConstant('LONGTEXT_LEN_MAX'))){
			return new static($len, static::LONGTEXT);
		}
		
		return null;
		
	}
public static function parse ( $ object ) { $ len = \ strlen ( $ object ) ; if ( Number :: between ( $ len , MySQL :: getConstant ( 'CHAR_LEN_MIN' ) , MySQL :: getConstant ( 'CHAR_LEN_MAX' ) ) ) { return new static ( $ len , static :: CHAR ) ; } else if ( Number :: between ( $ len , MySQL :: getConstant ( 'VARCHAR_LEN_MIN' ) , MySQL :: getConstant ( 'VARCHAR_LEN_MAX' ) ) ) { return new static ( $ len , static :: VARCHAR ) ; } else if ( Number :: between ( $ len , MySQL :: getConstant ( 'MEDIUMTEXT_LEN_MIN' ) , MySQL :: getConstant ( 'MEDIUMTEXT_LEN_MAX' ) ) ) { return new static ( $ len , static :: MEDIUMTEXT ) ; } else if ( Number :: between ( $ len , MySQL :: getConstant ( 'LONGTEXT_LEN_MIN' ) , MySQL :: getConstant ( 'LONGTEXT_LEN_MAX' ) ) ) { return new static ( $ len , static :: LONGTEXT ) ; } return null ; }
Parse a string object to a MySQL string type
Prefers VARCHARs over BLOBs
@param mixed $object
@return \static
Parse a string object to a MySQL string type Prefers VARCHARs over BLOBs