0 follower

Final Class Yiisoft\Hydrator\Attribute\Parameter\LeftTrim

InheritanceYiisoft\Hydrator\Attribute\Parameter\LeftTrim
ImplementsYiisoft\Hydrator\Attribute\Parameter\ParameterAttributeInterface

Strip whitespace (or other characters) from the beginning of a resolved string value.

See also https://www.php.net/manual/function.ltrim.php.

Public Properties

Hide inherited properties

Property Type Description Defined By
$characters string|null Yiisoft\Hydrator\Attribute\Parameter\LeftTrim

Property Details

Hide inherited properties

$characters public property
public string|null $characters null

Method Details

Hide inherited methods

__construct() public method

public mixed __construct ( string|null $characters null )
$characters string|null

The list all characters that you want to be stripped. With .. you can specify a range of characters.

                public function __construct(
    public readonly ?string $characters = null,
) {
}

            
getResolver() public method

public string getResolver ( )

                public function getResolver(): string
{
    return LeftTrimResolver::class;
}