Module org.meeuw.i18n.countries
Package org.meeuw.i18n.countries
Class AbstractCurrentCountryProvider
- java.lang.Object
-
- org.meeuw.i18n.countries.AbstractCurrentCountryProvider
-
- All Implemented Interfaces:
RegionProvider<CurrentCountry>
- Direct Known Subclasses:
CurrentCountryProvider
,UnofficialCurrentCountryProvider
public abstract class AbstractCurrentCountryProvider extends Object implements RegionProvider<CurrentCountry>
- Since:
- 0.1
- Author:
- Michiel Meeuwissen
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractCurrentCountryProvider(Set<com.neovisionaries.i18n.CountryCode.Assignment> assignments)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Optional<CurrentCountry>
getByCode(@NonNull String code, boolean lenient)
Class<CurrentCountry>
getProvidedClass()
Stream<CurrentCountry>
values()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.meeuw.i18n.spi.RegionProvider
canProvide, getByCode, getByCodeOrNull
-
-
-
-
Constructor Detail
-
AbstractCurrentCountryProvider
protected AbstractCurrentCountryProvider(Set<com.neovisionaries.i18n.CountryCode.Assignment> assignments)
-
-
Method Detail
-
getProvidedClass
public Class<CurrentCountry> getProvidedClass()
- Specified by:
getProvidedClass
in interfaceRegionProvider<CurrentCountry>
-
getByCode
public Optional<CurrentCountry> getByCode(@NonNull String code, boolean lenient)
- Specified by:
getByCode
in interfaceRegionProvider<CurrentCountry>
-
values
public Stream<CurrentCountry> values()
- Specified by:
values
in interfaceRegionProvider<CurrentCountry>
-
-