|
6 | 6 | package io.openapiprocessor.core.processor.mapping.v2 |
7 | 7 |
|
8 | 8 | import io.openapiprocessor.core.converter.mapping.* |
| 9 | +import io.openapiprocessor.core.converter.mapping.Annotation |
| 10 | +import io.openapiprocessor.core.converter.mapping.Mapping |
9 | 11 | import io.openapiprocessor.core.parser.HttpMethod |
10 | 12 | import io.openapiprocessor.core.processor.BadMappingException |
11 | | -import io.openapiprocessor.core.processor.mapping.v2.parser.Mapping as ParserMapping |
12 | 13 | import io.openapiprocessor.core.processor.mapping.v2.parser.Mapping.Kind.ANNOTATE |
13 | 14 | import io.openapiprocessor.core.processor.mapping.v2.parser.MappingType |
14 | 15 | import io.openapiprocessor.core.processor.mapping.v2.parser.antlr.parseMapping |
15 | | -import java.util.stream.Collectors |
16 | | -import io.openapiprocessor.core.processor.mapping.v2.Mapping as MappingV2 |
17 | 16 | import io.openapiprocessor.core.processor.mapping.v2.Map as MapV2 |
| 17 | +import io.openapiprocessor.core.processor.mapping.v2.Mapping as MappingV2 |
| 18 | +import io.openapiprocessor.core.processor.mapping.v2.parser.Mapping as ParserMapping |
| 19 | +import java.util.stream.Collectors |
18 | 20 |
|
19 | 21 | /** |
20 | 22 | * Converter for the type mapping from the mapping yaml. It converts the type mapping information |
@@ -247,10 +249,9 @@ class MappingConverter(val mapping: MappingV2) { |
247 | 249 | mapping.targetTypePrimitiveArray |
248 | 250 | ) |
249 | 251 |
|
250 | | - var annotation: io.openapiprocessor.core.converter.mapping.Annotation? = null |
| 252 | + var annotation: Annotation? = null |
251 | 253 | if(mapping.annotationType != null) { |
252 | | - annotation = Annotation( |
253 | | - mapping.annotationType!!, mapping.annotationParameters) |
| 254 | + annotation = Annotation(mapping.annotationType!!, mapping.annotationParameters) |
254 | 255 | } |
255 | 256 |
|
256 | 257 | return AddParameterTypeMapping(mapping.sourceType!!, typeMapping, annotation) |
|
0 commit comments