presto-main/src/main/java/io/prestosql/operator/scalar/UrlFunctions.java/UrlFunctions/urlExtractProtocol
class UrlFunctions:    @SqlNullable
    @Description("extract protocol from url")
    @ScalarFunction
    @LiteralParameters("x")
    @SqlType("varchar(x)")
    public static Slice urlExtractProtocol(@SqlType("varchar(x)") Slice url)
    {
        URI uri = parseUrl(url);
        return (uri == null) ? null : slice(uri.getScheme());
    }