static String segmentsToPath(PathMappingType mappingType, List<PathSegment> segments,
                                     boolean withLeadingSlash) {
            requireNonNull(segments, "segments");
            final String path = toPathString(segments, mappingType);
            return withLeadingSlash ? '/' + path : path;
        }
Returns whether the specified {@link PathMappingType} is supported by
this {@link PathSegment}.
grpc/src/main/java/com/linecorp/armeria/server/grpc/HttpJsonTranscodingPathParser.java