MavenRepositoryClient implements MavenRepository { static URI withArtifactPath(URI baseUrl, ArtifactId id) { List<String> parts = new ArrayList<>(List.of(id.groupId().split("\\."))); parts.add(id.artifactId()); parts.add("maven-metadata.xml"); return baseUrl.resolve(String.join("/", parts)); } MavenRepositoryClient(MavenRepositoryConfig config); @Override Metadata metadata(); @Override ArtifactId artifactId();  }
@Test public void testUri() { assertEquals(URI.create("https: MavenRepositoryClient.withArtifactPath(URI.create("https: new ArtifactId("group.id", "artifact-id"))); }