Commit 11db3293 authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Rename LanguageFieldMapper to LanguageMapper

parent d8332c71
......@@ -30,7 +30,7 @@ import org.memobase.mapping.mappers.ConstantFieldMapper
import org.memobase.mapping.mappers.DateFieldMapper
import org.memobase.mapping.mappers.IFieldMapper
import org.memobase.mapping.mappers.IdentifierFieldMapper
import org.memobase.mapping.mappers.LanguageFieldMapper
import org.memobase.mapping.mappers.LanguageMapper
import org.memobase.mapping.mappers.LanguageTagFieldMapper
import org.memobase.mapping.mappers.ListFieldMapper
import org.memobase.mapping.mappers.PlaceFieldMapper
......@@ -349,7 +349,7 @@ class MappingConfig(directory: String) {
subEntry, languageTypes
)
if (configField is SimpleField) {
recordFieldMappers.add(LanguageFieldMapper(configField))
recordFieldMappers.add(LanguageMapper(configField))
} else
throw InvalidMappingException("Languages only allow simple direct mappings.")
}
......
......@@ -21,7 +21,7 @@ package org.memobase.mapping.mappers
import org.memobase.builder.IResource
import org.memobase.mapping.fields.SimpleField
class LanguageFieldMapper(private val simpleField: SimpleField) :
class LanguageMapper(private val simpleField: SimpleField) :
IFieldMapper {
override fun apply(source: Map<String, String>, subject: IResource) {
if (source.containsKey(simpleField.field)) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment