ru.foodtechlab.lib.auth.service.domain.preference.config.ServicePreferenceConfig Maven / Gradle / Ivy
package ru.foodtechlab.lib.auth.service.domain.preference.config;
import lombok.Getter;
import lombok.experimental.Accessors;
import ru.foodtechlab.lib.auth.service.domain.role.port.RoleRepository;
import ru.foodtechlab.lib.auth.service.domain.preference.port.ServicePreferenceIdGenerator;
import ru.foodtechlab.lib.auth.service.domain.preference.port.ServicePreferenceRepository;
import ru.foodtechlab.lib.auth.service.domain.preference.usecase.CreateServicePreferenceUseCase;
import ru.foodtechlab.lib.auth.service.domain.preference.usecase.GetServicePreferenceUseCase;
import ru.foodtechlab.lib.auth.service.domain.preference.usecase.GetTTLForAuthWithConfirmationUseCase;
import ru.foodtechlab.lib.auth.service.domain.preference.usecase.UpdateServicePreferenceUseCase;
@Accessors(fluent = true)
@Getter
public class ServicePreferenceConfig {
private final CreateServicePreferenceUseCase createSettings;
private final GetServicePreferenceUseCase getSettings;
private final GetTTLForAuthWithConfirmationUseCase getTTLForAuthWithConfirmation;
private final UpdateServicePreferenceUseCase updateSettings;
public ServicePreferenceConfig(ServicePreferenceRepository servicePreferenceRepository, ServicePreferenceIdGenerator> servicePreferenceIdGenerator, RoleRepository roleRepository) {
this.createSettings = new CreateServicePreferenceUseCase(servicePreferenceRepository, servicePreferenceIdGenerator);
this.getSettings = new GetServicePreferenceUseCase(servicePreferenceRepository, createSettings);
this.getTTLForAuthWithConfirmation = new GetTTLForAuthWithConfirmationUseCase(getSettings);
this.updateSettings = new UpdateServicePreferenceUseCase(servicePreferenceRepository, getSettings);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy