All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.castled.forms.StaticOptionsFetcherFactory Maven / Gradle / Ivy

There is a newer version: 1.0.0
Show newest version
package io.castled.forms;

import io.castled.forms.dtos.FormFieldOption;

import javax.inject.Inject;
import javax.inject.Singleton;
import java.util.List;
import java.util.Map;

@Singleton
public class StaticOptionsFetcherFactory {

    private final Map staticOptionsFetchers;

    @Inject
    public StaticOptionsFetcherFactory(Map staticOptionsFetchers) {
        this.staticOptionsFetchers = staticOptionsFetchers;
    }

    public List getOptions(String optionsRef) {
        return staticOptionsFetchers.get(optionsRef).getOptions();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy