<commit_before>package org.hisp.dhis.android.core.common;

import org.hisp.dhis.android.core.category.CategoryCombo;
import org.hisp.dhis.android.core.category.CategoryOption;
import org.hisp.dhis.android.core.data.database.DatabaseAdapter;
import org.hisp.dhis.android.core.event.EventEndPointCall;
import org.hisp.dhis.android.core.event.EventQuery;

import java.util.Date;

import retrofit2.Retrofit;

public class EventCallFactory {
    public static EventEndPointCall create(Retrofit retrofit,
            DatabaseAdapter databaseAdapter, String orgUnit, int pageLimit) {

        EventQuery eventQuery = EventQuery.Builder
                .create()
                .withOrgUnit(orgUnit)
                .withPageLimit(pageLimit)
                .build();

        GenericCallData data = GenericCallData.create(databaseAdapter, retrofit, new Date());
        return EventEndPointCall.create(data, eventQuery);
    }

    public static EventEndPointCall create(Retrofit retrofit,
            DatabaseAdapter databaseAdapter, String orgUnit, int pageLimit, String categoryComboUID,
            String categoryOptionUID) {

        CategoryCombo categoryCombo = CategoryCombo
                .builder()
                .uid(categoryComboUID)
                .build();

        CategoryOption categoryOption = CategoryOption
                .builder()
                .uid(categoryOptionUID)
                .build();

        EventQuery eventQuery = EventQuery.Builder
                .create()
                .withOrgUnit(orgUnit)
                .withPageLimit(pageLimit)
                .withCategoryComboAndCategoryOption(categoryCombo, categoryOption)
                .build();

        GenericCallData data = GenericCallData.create(databaseAdapter, retrofit, new Date());
        return EventEndPointCall.create(data, eventQuery);
    }
}<commit_msg>n-events-call: adapt EventCallFactory<commit_after>package org.hisp.dhis.android.core.common;

import org.hisp.dhis.android.core.category.CategoryCombo;
import org.hisp.dhis.android.core.category.CategoryOption;
import org.hisp.dhis.android.core.data.database.DatabaseAdapter;
import org.hisp.dhis.android.core.event.EventEndpointCall;
import org.hisp.dhis.android.core.event.EventQuery;

import java.util.Date;

import retrofit2.Retrofit;

public class EventCallFactory {
    public static EventEndpointCall create(Retrofit retrofit,
                                           DatabaseAdapter databaseAdapter, String orgUnit, int pageLimit) {

        EventQuery eventQuery = EventQuery.Builder
                .create()
                .withOrgUnit(orgUnit)
                .withPageLimit(pageLimit)
                .build();

        GenericCallData data = GenericCallData.create(databaseAdapter, retrofit, new Date());
        return EventEndpointCall.create(data.retrofit(), eventQuery);
    }

    public static EventEndpointCall create(Retrofit retrofit,
                                           DatabaseAdapter databaseAdapter, String orgUnit, int pageLimit, String categoryComboUID,
                                           String categoryOptionUID) {

        CategoryCombo categoryCombo = CategoryCombo
                .builder()
                .uid(categoryComboUID)
                .build();

        CategoryOption categoryOption = CategoryOption
                .builder()
                .uid(categoryOptionUID)
                .build();

        EventQuery eventQuery = EventQuery.Builder
                .create()
                .withOrgUnit(orgUnit)
                .withPageLimit(pageLimit)
                .withCategoryComboAndCategoryOption(categoryCombo, categoryOption)
                .build();

        GenericCallData data = GenericCallData.create(databaseAdapter, retrofit, new Date());
        return EventEndpointCall.create(data.retrofit(), eventQuery);
    }
}
{'fraction_non_alphanumeric': 0.08115115374643506, 'fraction_numerical': 0.0005185377236193933, 'mean_word_length': 2.33160621761658, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4233644', 'n_tokens_mistral': 984, 'n_tokens_neox': 950, 'n_words': 184}