Package com.atlassian.jira.ofbiz
Interface OfBizListIterator
- All Superinterfaces:
AutoCloseable
,Iterable<org.ofbiz.core.entity.GenericValue>
- All Known Implementing Classes:
DefaultOfBizListIterator
,MockOfBizListIterator
@PublicApi
public interface OfBizListIterator
extends Iterable<org.ofbiz.core.entity.GenericValue>, AutoCloseable
A wrapper around
EntityListIterator
that does not throw
GenericEntityException
.
IMPORTANT: Note that you should not rely on this for streaming large datasets, as the backing ResultSet will pull the entire dataset into memory anyway. For more information, see PSA: OfBizListIterator is not good enough.
IMPORTANT: This iterator must be closed in a finally
block, or connection leaks will ensue.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
absolute
(int i) void
add
(org.ofbiz.core.entity.GenericValue o) void
void
void
close()
Closes the iterator.org.ofbiz.core.entity.GenericValue
int
boolean
first()
List<org.ofbiz.core.entity.GenericValue>
List<org.ofbiz.core.entity.GenericValue>
getPartialList
(int i, int i1) boolean
isCaseSensitive
(String fieldName) Returns true if the specified field name in the database is case-sensitive.Iterator<org.ofbiz.core.entity.GenericValue>
iterator()
Returns a read-only iterator over the result sets.boolean
last()
org.ofbiz.core.entity.GenericValue
next()
int
org.ofbiz.core.entity.GenericValue
previous()
int
void
remove()
void
set
(org.ofbiz.core.entity.GenericValue o) void
setDelegator
(org.ofbiz.core.entity.GenericDelegator genericDelegator) void
setFetchSize
(int i) Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Method Details
-
setDelegator
void setDelegator(org.ofbiz.core.entity.GenericDelegator genericDelegator) -
afterLast
void afterLast() -
beforeFirst
void beforeFirst() -
last
boolean last() -
first
boolean first() -
close
void close()Closes the iterator. Logs exceptions and does not propagate them.- Specified by:
close
in interfaceAutoCloseable
-
currentGenericValue
org.ofbiz.core.entity.GenericValue currentGenericValue() -
currentIndex
int currentIndex() -
absolute
boolean absolute(int i) -
next
org.ofbiz.core.entity.GenericValue next() -
nextIndex
int nextIndex() -
previous
org.ofbiz.core.entity.GenericValue previous() -
previousIndex
int previousIndex() -
setFetchSize
void setFetchSize(int i) -
getCompleteList
List<org.ofbiz.core.entity.GenericValue> getCompleteList() -
getPartialList
-
add
void add(org.ofbiz.core.entity.GenericValue o) -
remove
void remove() -
set
void set(org.ofbiz.core.entity.GenericValue o) -
isCaseSensitive
Returns true if the specified field name in the database is case-sensitive.- Parameters:
fieldName
- the name of the entity field- Returns:
- true if the field is case-sensitive in the database
- Throws:
DataAccessException
- if an underlying problem occurs.
-
iterator
Iterator<org.ofbiz.core.entity.GenericValue> iterator()Returns a read-only iterator over the result sets.
-