Package org.hcjf.layers.storage.actions
Class ResultSet<O>
- java.lang.Object
-
- org.hcjf.layers.storage.actions.ResultSet<O>
-
- All Implemented Interfaces:
java.lang.Iterable<O>,java.util.Collection<O>
public class ResultSet<O> extends java.lang.Object implements java.util.Collection<O>This object is the result for all the queries executed using the storage layer. This object is basically an wrapper of a collection that is configured into the constructor.- Author:
- javaito
-
-
Method Summary
Modifier and Type Method Description booleanadd(O o)booleanaddAll(java.util.Collection<? extends O> c)voidclear()booleancontains(java.lang.Object o)booleancontainsAll(java.util.Collection<?> c)booleanequals(java.lang.Object o)voidforEach(java.util.function.Consumer<? super O> action)java.lang.LonggetAdaptationTime()Returns the time consumed adapting the original query.java.lang.IntegergetAffectedInstances()Returns the number of affected storage instances after the execution.java.lang.LonggetExecutionTime()Returns the time consumed executing the action on the underlying technology.java.lang.LonggetPresentationTime()Returns the time consumed transforming the raw information to the expected presentation format.java.lang.LonggetTotalTime()Returns the total time consumed performing the operation.java.lang.LonggetValidationIntegrityTime()Returns the time consumed validating the data integrity.inthashCode()booleanisEmpty()java.util.Iterator<O>iterator()java.util.stream.Stream<O>parallelStream()booleanremove(java.lang.Object o)booleanremoveAll(java.util.Collection<?> c)booleanremoveIf(java.util.function.Predicate<? super O> filter)booleanretainAll(java.util.Collection<?> c)intsize()java.util.Spliterator<O>spliterator()java.util.stream.Stream<O>stream()java.lang.Object[]toArray()<T> T[]toArray(T[] a)
-
-
-
Constructor Detail
-
ResultSet
public ResultSet(java.util.Collection<O> result, java.lang.Integer affectedInstances, java.lang.Long adaptationTime, java.lang.Long executionTime, java.lang.Long presentationTime, java.lang.Long validationIntegrityTime, java.lang.Long totalTime)
-
-
Method Detail
-
getAffectedInstances
public java.lang.Integer getAffectedInstances()
Returns the number of affected storage instances after the execution.- Returns:
- Number of the affected storage instances.
-
getAdaptationTime
public java.lang.Long getAdaptationTime()
Returns the time consumed adapting the original query.- Returns:
- Adaptation time.
-
getExecutionTime
public java.lang.Long getExecutionTime()
Returns the time consumed executing the action on the underlying technology.- Returns:
- Execution time.
-
getPresentationTime
public java.lang.Long getPresentationTime()
Returns the time consumed transforming the raw information to the expected presentation format.- Returns:
- Presentation time.
-
getValidationIntegrityTime
public java.lang.Long getValidationIntegrityTime()
Returns the time consumed validating the data integrity.- Returns:
- Validation integrity time.
-
getTotalTime
public java.lang.Long getTotalTime()
Returns the total time consumed performing the operation.- Returns:
- Total time.
-
size
public int size()
- Specified by:
sizein interfacejava.util.Collection<O>
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfacejava.util.Collection<O>
-
contains
public boolean contains(java.lang.Object o)
- Specified by:
containsin interfacejava.util.Collection<O>
-
iterator
public java.util.Iterator<O> iterator()
-
toArray
public java.lang.Object[] toArray()
- Specified by:
toArrayin interfacejava.util.Collection<O>
-
toArray
public <T> T[] toArray(T[] a)
- Specified by:
toArrayin interfacejava.util.Collection<O>
-
remove
public boolean remove(java.lang.Object o)
- Specified by:
removein interfacejava.util.Collection<O>
-
containsAll
public boolean containsAll(java.util.Collection<?> c)
- Specified by:
containsAllin interfacejava.util.Collection<O>
-
addAll
public boolean addAll(java.util.Collection<? extends O> c)
- Specified by:
addAllin interfacejava.util.Collection<O>
-
removeAll
public boolean removeAll(java.util.Collection<?> c)
- Specified by:
removeAllin interfacejava.util.Collection<O>
-
removeIf
public boolean removeIf(java.util.function.Predicate<? super O> filter)
- Specified by:
removeIfin interfacejava.util.Collection<O>
-
retainAll
public boolean retainAll(java.util.Collection<?> c)
- Specified by:
retainAllin interfacejava.util.Collection<O>
-
clear
public void clear()
- Specified by:
clearin interfacejava.util.Collection<O>
-
equals
public boolean equals(java.lang.Object o)
- Specified by:
equalsin interfacejava.util.Collection<O>- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfacejava.util.Collection<O>- Overrides:
hashCodein classjava.lang.Object
-
spliterator
public java.util.Spliterator<O> spliterator()
-
stream
public java.util.stream.Stream<O> stream()
- Specified by:
streamin interfacejava.util.Collection<O>
-
parallelStream
public java.util.stream.Stream<O> parallelStream()
- Specified by:
parallelStreamin interfacejava.util.Collection<O>
-
-