fatcode/hydration

View on GitHub
src/Type/StringType.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php declare(strict_types=1);

namespace FatCode\Hydration\Type;

class StringType implements Type, NullableType
{
    use Nullable;

    public function hydrate($value): string
    {
        return (string) $value;
    }

    public function extract($value): string
    {
        return (string) $value;
    }
}