LocalizationScheme
public enum LocalizationScheme
Configure your SynchronizationManager instance with a localization scheme to define which data should
be saved to your persistent store. The LocalizationScheme.default
scheme will save entities representing
data only for the default locale of your space, while the LocalizationScheme.all
will save data
for all locales.
-
Use the
.default
scheme to save only for the default locale for your space.Declaration
Swift
case `default`
-
Specify that data should be saved for only one locale using this scheme. For example the scheme,
LocalizationScheme.one("es-MX")
, will configure this library to only save data for Mexican Spanish. Not that anassertionFailure
will be thrown if Mexican Spanish is not a valid locale on your space.Declaration
Swift
case one(LocaleCode)
-
Require that data for all locales be saved to your persistent store. Remember to specify a predicate that includes pattern matching for the
localeCode
property of yourPersistable
model classes when fetching from your local database.Declaration
Swift
case all