Class DefaultConverter<S,​T>

  • Type Parameters:
    S - the type of the input of the converter.
    T - the type of the output of the converter.
    All Implemented Interfaces:
    Converter<S,​T>

    public class DefaultConverter<S,​T>
    extends java.lang.Object
    implements Converter<S,​T>
    Default implementation of Converter. Requires an ObjectFactory to create instances of the prototyped target object and a list of Populator to populate the target object.
    • Constructor Detail

      • DefaultConverter

        public DefaultConverter()
    • Method Detail

      • convert

        public T convert​(S s)
        Description copied from interface: Converter
        Uses the source S object and produces an new instance of T.
        Specified by:
        convert in interface Converter<S,​T>
        Parameters:
        s - the input to be converted.
        Returns:
        an instance of T, converted from the input source.
      • getPopulators

        protected java.util.List<Populator<S,​T>> getPopulators()
      • setPopulators

        public void setPopulators​(java.util.List<Populator<S,​T>> populators)
      • getObjectFactory

        public org.springframework.beans.factory.ObjectFactory<T> getObjectFactory()
      • setObjectFactory

        public void setObjectFactory​(org.springframework.beans.factory.ObjectFactory<T> objectFactory)