Class SecureSet<E>
java.lang.Object
org.exoplatform.commons.utils.secure.SecureSet<E>
- All Implemented Interfaces:
Iterable<E>,Collection<E>,Set<E>
SecureSet is a wrapper over given Set instance providing additional security check.
To be able to modify set, invoking code must have the same permission as given in SecureSet's
constructor or
AllPermission.- Version:
- $Id: SecureSet.java 34360 2009-07-22 23:58:59Z nzamosenchuk $
- Author:
- Nikolay Zamosenchuk
-
Constructor Summary
ConstructorsConstructorDescriptionSecureSet(Permission permission) Constructs a SecureSet using newHashSetinside.SecureSet(Set<E> set, Permission permission) Constructs a SecureSet using new givenSetinstance. -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanaddAll(Collection<? extends E> elements) voidclear()booleanbooleancontainsAll(Collection<?> coll) booleaninthashCode()booleanisEmpty()iterator()booleanbooleanremoveAll(Collection<?> pds) booleanretainAll(Collection<?> pds) intsize()Object[]toArray()<T> T[]toArray(T[] a) toString()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.Set
spliterator
-
Constructor Details
-
Method Details
-
add
-
addAll
-
clear
public void clear() -
contains
-
containsAll
- Specified by:
containsAllin interfaceCollection<E>- Specified by:
containsAllin interfaceSet<E>
-
equals
-
hashCode
public int hashCode() -
isEmpty
public boolean isEmpty() -
iterator
-
remove
-
removeAll
-
retainAll
-
size
public int size() -
toArray
-
toArray
public <T> T[] toArray(T[] a) -
toString
-