src/Schema/AbstractColumn.php
public function string(int $size = 255): AbstractColumn
    {
        $this->type('string');

        if ($size > 255) {
            throw new SchemaException("String size can't exceed 255 characters. Use text instead");
        }

        if ($size < 0) {
            throw new SchemaException('Invalid string length value');
        }

        $this->size = (int)$size;

        return $this;
    }
public function string(int $size = 255): AbstractColumn
    {
        $this->type('string');

        if ($size > 255) {
            throw new SchemaException("String size can't exceed 255 characters. Use text instead");
        }

        if ($size < 0) {
            throw new SchemaException('Invalid string length value');
        }

        $this->size = (int)$size;

        return $this;
    }
public function string ( int $ size = 255 ) : AbstractColumn { $ this -> type ( 'string' ) ; if ( $ size > 255 ) { throw new SchemaException ( "String size can't exceed 255 characters. Use text instead" ) ; } if ( $ size < 0 ) { throw new SchemaException ( 'Invalid string length value' ) ; } $ this -> size = ( int ) $ size ; return $ this ; }
Set column type as string with limited size. Maximum allowed size is 255 bytes, use "text"
abstract types for longer strings.

Strings are perfect type to store email addresses as it big enough to store valid address
and
can be covered with unique index.

@link http://stackoverflow.com/questions/386294/what-is-the-maximum-length-of-a-valid-email-address

@param int $size Max string length.
@return self|$this

@throws SchemaException
Set column type as string with limited size . Maximum allowed size is 255 bytes use text abstract types for longer strings .