Class ReportingSet<T>
java.lang.Object
org.apache.rat.utils.ReportingSet<T>
- Type Parameters:
T- the type of object
- All Implemented Interfaces:
Iterable<T>, Collection<T>, Set<T>, SortedSet<T>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumThe Options for duplicate processing -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanaddAll(Collection<? extends T> c) booleanaddAllIfNotPresent(Collection<? extends T> c) booleanaddIfNotPresent(T e) Adds the item if it is not present.voidclear()Comparator<? super T> booleanbooleancontainsAll(Collection<?> c) booleanfirst()voidinthashCode()booleanisEmpty()iterator()last()booleanbooleanremoveAll(Collection<?> c) booleanbooleanretainAll(Collection<?> c) If set true attempts to duplicate will throw an IllegalArgumentException.setLogLevel(Log.Level level) Sets the log level that the reporting set will log at. if not set the default level is WARN.setMsgFormat(Function<T, String> msgFmt) Sets the function to generate the log message.intsize()stream()Object[]toArray()<T> T[]toArray(T[] a) Methods inherited from class Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Collection
toArray
-
Constructor Details
-
ReportingSet
-
-
Method Details
-
setMsgFormat
Sets the function to generate the log message.- Parameters:
msgFmt- A function to return the string to be displayed when a collision occurs.- Returns:
- This for chaining.
-
setDuplicateOption
If set true attempts to duplicate will throw an IllegalArgumentException. The default state is false;.- Parameters:
state- the state to set.- Returns:
- this for chaining.
-
setLogLevel
Sets the log level that the reporting set will log at. if not set the default level is WARN.- Parameters:
level- the log level to use.- Returns:
- this for chaining.
-
addIfNotPresent
Adds the item if it is not present. Does not report collisions.- Parameters:
e- the item to add.- Returns:
- true if the item was added, false otherwise.
-
add
-
addAll
-
addAllIfNotPresent
-
clear
-
comparator
- Specified by:
comparatorin interfaceSortedSet<T>
-
contains
-
containsAll
- Specified by:
containsAllin interfaceCollection<T>- Specified by:
containsAllin interfaceSet<T>
-
equals
-
first
-
forEach
-
hashCode
-
headSet
-
isEmpty
-
iterator
-
last
-
parallelStream
- Specified by:
parallelStreamin interfaceCollection<T>
-
remove
-
removeAll
-
removeIf
- Specified by:
removeIfin interfaceCollection<T>
-
retainAll
-
size
-
spliterator
- Specified by:
spliteratorin interfaceCollection<T>- Specified by:
spliteratorin interfaceIterable<T>- Specified by:
spliteratorin interfaceSet<T>- Specified by:
spliteratorin interfaceSortedSet<T>
-
stream
- Specified by:
streamin interfaceCollection<T>
-
subSet
-
tailSet
-
toArray
-
toArray
-