@Documented @Retention(value=CLASS) @Target(value=TYPE_USE) public @interface Unmodifiable
Collection
or Map
type
as unmodifiable. A collection or a map is unmodifiable if any mutator methods
(e.g. Collection.add(Object)
) throw exception or have no effect,
and the object references stored as collection elements, map keys, and map values
are never changed. The referenced objects themselves still could be changed if they
are mutable.UnmodifiableView
Copyright © 2024. All rights reserved.