Class NoEntryWrapperListSerializer<T>
- java.lang.Object
-
- com.fasterxml.jackson.databind.JsonSerializer<List<T>>
-
- io.adminshell.aas.v3.dataformat.xml.serialization.NoEntryWrapperListSerializer<T>
-
- Type Parameters:
T- serialized class within the list
- All Implemented Interfaces:
com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitable
- Direct Known Subclasses:
LangStringsSerializer
public class NoEntryWrapperListSerializer<T> extends com.fasterxml.jackson.databind.JsonSerializer<List<T>>
Custom serializer for lists without individual list entry wrappers for parametrized classes.
-
-
Constructor Summary
Constructors Constructor Description NoEntryWrapperListSerializer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisEmpty(com.fasterxml.jackson.databind.SerializerProvider provider, List<T> value)voidserialize(List<T> list, com.fasterxml.jackson.core.JsonGenerator gen, com.fasterxml.jackson.databind.SerializerProvider serializers)voidsetOuterWrapper(String outerWrapper)Sets the tag-name of the outer xml wrapper element.
-
-
-
Method Detail
-
setOuterWrapper
public void setOuterWrapper(String outerWrapper)
Sets the tag-name of the outer xml wrapper element. By default, no outer wrapper is serialized.- Parameters:
outerWrapper- the tag name (without namespace)
-
serialize
public void serialize(List<T> list, com.fasterxml.jackson.core.JsonGenerator gen, com.fasterxml.jackson.databind.SerializerProvider serializers) throws IOException
- Specified by:
serializein classcom.fasterxml.jackson.databind.JsonSerializer<List<T>>- Throws:
IOException
-
-