Class PrototypeFactory.PrototypeSerializationFactory<T extends Serializable>

java.lang.Object
org.apache.commons.collections4.functors.PrototypeFactory.PrototypeSerializationFactory<T>
All Implemented Interfaces:
Factory<T>
Enclosing class:
PrototypeFactory

static class PrototypeFactory.PrototypeSerializationFactory<T extends Serializable> extends Object implements Factory<T>
PrototypeSerializationFactory creates objects by cloning a prototype using serialization.
  • Field Details

    • iPrototype

      private final T extends Serializable iPrototype
      The object to clone via serialization each time
  • Constructor Details

    • PrototypeSerializationFactory

      private PrototypeSerializationFactory(T prototype)
      Constructor to store prototype
  • Method Details

    • create

      public T create()
      Creates an object using serialization.
      Specified by:
      create in interface Factory<T extends Serializable>
      Returns:
      the new object