<commit_before>package org.xcolab.util.http.client;

import org.xcolab.util.http.UriProvider;
import org.xcolab.util.http.client.interfaces.AbstractHttpResource;
import org.xcolab.util.http.client.interfaces.HttpEndpoint;
import org.xcolab.util.http.client.interfaces.HttpResource;
import org.xcolab.util.http.client.queries.ServiceQuery;

public class ServiceResource extends AbstractHttpResource implements HttpResource {
    private final UriProvider baseUrl;

    public ServiceResource(HttpEndpoint serviceOrParent, String resourceName) {
        super(resourceName);
        this.baseUrl = serviceOrParent.getBaseUrl();
    }

    @Override
    public UriProvider getBaseUrl() {
        return baseUrl;
    }

    public <O> ServiceQuery<O> service(long id, String serviceEndpoint, Class<O> returnType) {
        return new ServiceQuery<>(this, id, serviceEndpoint, returnType);
    }

    public <O> ServiceQuery<O> service(String id, String serviceEndpoint, Class<O> returnType) {
        return new ServiceQuery<>(this, id, serviceEndpoint, returnType);
    }

    public <O> ServiceQuery<O> service(String serviceEndpoint, Class<O> returnType) {
        return new ServiceQuery<>(this, serviceEndpoint, returnType);
    }
<commit_msg>Service resource fix<commit_after>package org.xcolab.util.http.client;

import org.xcolab.util.http.UriProvider;
import org.xcolab.util.http.client.interfaces.AbstractHttpResource;
import org.xcolab.util.http.client.interfaces.HttpEndpoint;
import org.xcolab.util.http.client.interfaces.HttpResource;
import org.xcolab.util.http.client.queries.ServiceQuery;

public class ServiceResource extends AbstractHttpResource implements HttpResource {

    private final HttpEndpoint serviceOrParent;
    public ServiceResource(HttpEndpoint serviceOrParent, String resourceName) {
        super(resourceName);
        this.serviceOrParent = serviceOrParent;
    }

    @Override
    public UriProvider getBaseUrl() {
        return serviceOrParent.getBaseUrl();
    }

    public <O> ServiceQuery<O> service(long id, String serviceEndpoint, Class<O> returnType) {
        return new ServiceQuery<>(this, id, serviceEndpoint, returnType);
    }

    public <O> ServiceQuery<O> service(String id, String serviceEndpoint, Class<O> returnType) {
        return new ServiceQuery<>(this, id, serviceEndpoint, returnType);
    }

    public <O> ServiceQuery<O> service(String serviceEndpoint, Class<O> returnType) {
        return new ServiceQuery<>(this, serviceEndpoint, returnType);
    }

{'fraction_non_alphanumeric': 0.09603174603174604, 'fraction_numerical': 0.0, 'mean_word_length': 4.492374727668845, 'pattern_counts': {'":': 0, '<': 27, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5532708', 'n_tokens_mistral': 711, 'n_tokens_neox': 703, 'n_words': 160}