diff --git a/src/Formatters/StringFormatter.php b/src/Formatters/StringFormatter.php new file mode 100644 index 0000000..ccd1bdd --- /dev/null +++ b/src/Formatters/StringFormatter.php @@ -0,0 +1,30 @@ + + * + * @author Peter Lai + * @license MIT + */ + +namespace Web3\Formatters; + +use InvalidArgumentException; +use Web3\Utils; +use Web3\Formatters\IFormatter; + +class StringFormatter implements IFormatter +{ + /** + * format + * + * @param mixed $value + * @return string + */ + public static function format($value) + { + return Utils::toString($value); + } +} \ No newline at end of file