Class SingletonCollectionConverter

  • All Implemented Interfaces:
    Converter, ConverterMatcher

    public class SingletonCollectionConverter
    extends CollectionConverter
    Converts singleton collections (list and set) to XML, specifying a nested element for the item.

    Supports Collections.singleton(Object) and Collections.singletonList(Object).

    Since:
    1.4.2
    • Field Detail

      • LIST

        private static final java.lang.Class LIST
      • SET

        private static final java.lang.Class SET
    • Constructor Detail

      • SingletonCollectionConverter

        public SingletonCollectionConverter​(Mapper mapper)
        Construct a SingletonCollectionConverter.
        Parameters:
        mapper - the mapper
        Since:
        1.4.2