src/Encoder/Encoder.php
public static function instance(array $schemas = []): EncoderInterface
    {
        $factory   = static::createFactory();
        $container = $factory->createSchemaContainer($schemas);
        $encoder   = $factory->createEncoder($container);

        return $encoder;
    }
public static function instance(array $schemas = []): EncoderInterface
    {
        $factory   = static::createFactory();
        $container = $factory->createSchemaContainer($schemas);
        $encoder   = $factory->createEncoder($container);

        return $encoder;
    }
public static function instance ( array $ schemas = [ ] ) : EncoderInterface { $ factory = static :: createFactory ( ) ; $ container = $ factory -> createSchemaContainer ( $ schemas ) ; $ encoder = $ factory -> createEncoder ( $ container ) ; return $ encoder ; }
Create encoder instance.

@param array $schemas Schema providers.

@return EncoderInterface
Create encoder instance .