Class CollectionModel<T>

    • Constructor Detail

      • CollectionModel

        public CollectionModel​(java.util.Collection<T> collection)
        Creates model that will contain collection.
        Parameters:
        collection - the collection
      • CollectionModel

        public CollectionModel()
    • Method Detail

      • of

        public static <C> IModel<java.util.Collection<C>> of​(java.util.Collection<C> collection)
        Factory method for models that contain collections. This factory method will automatically rebuild a nonserializable collection into a serializable ArrayList.
        Type Parameters:
        C - model type
        Parameters:
        collection - The Collection, which may or may not be Serializable
        Returns:
        A IModel object wrapping the Set
      • newSerializableCollectionOf

        protected java.util.Collection<T> newSerializableCollectionOf​(java.util.Collection<T> object)
        Creates a serializable version of the object. The object is usually a collection.
        Specified by:
        newSerializableCollectionOf in class GenericCollectionModel<java.util.Collection<T>>
        Parameters:
        object - the object
        Returns:
        serializable version of object