
Classes | |
| class | FakeArray |
Public Member Functions | |
| int | batchCount () |
| NSArray< T > | displayedObjects () |
| ERXBatchingDisplayGroup () | |
| Object | fetch () |
| NSArray< T > | filteredObjects () |
| boolean | hasMultipleBatches () |
| boolean | isRawRowsForCustomQueries () |
| NSArray< String > | prefetchingRelationshipKeyPaths () |
| int | rowCount () |
| Object | selectFilteredObjects () |
| void | setCurrentBatchIndex (int index) |
| void | setDataSource (EODataSource eodatasource) |
| void | setNumberOfObjectsPerBatch (int count) |
| void | setObjectArray (NSArray objects) |
| void | setPrefetchingRelationshipKeyPaths (NSArray< String > prefetchingRelationshipKeyPaths) |
| void | setQualifier (EOQualifier aEoqualifier) |
| void | setRawRowsForCustomQueries (boolean rawRowsForCustomQueries) |
| void | setRowCount (int rowCount) |
| void | setShouldRememberRowCount (boolean shouldRememberRowCount) |
| void | setSortOrderings (NSArray nsarray) |
| boolean | shouldRememberRowCount () |
| void | updateDisplayedObjects () |
Static Public Member Functions | |
| static Object | decodeWithKeyValueUnarchiver (EOKeyValueUnarchiver unarchiver) |
Protected Member Functions | |
| EOFetchSpecification | fetchSpecification () |
| boolean | isBatching () |
| NSArray< T > | objectsInRange (int start, int end) |
| void | refetch () |
| void | refetchIfNecessary () |
| void | updateBatchCount () |
Protected Attributes | |
| int | _batchCount |
| NSArray< T > | _displayedObjects |
| Boolean | _isBatching |
| NSArray< String > | _prefetchingRelationshipKeyPaths |
| int | _rowCount = -1 |
| boolean | _shouldRememberRowCount = true |
Private Member Functions | |
| ERXBatchingDisplayGroup (EOKeyValueUnarchiver unarchiver) | |
Private Attributes | |
| boolean | _rawRowsForCustomQueries = true |
Static Private Attributes | |
| static final Logger | log = Logger.getLogger(ERXBatchingDisplayGroup.class) |
| ERXBatchingDisplayGroup | ( | ) |
Creates a new ERXBatchingDisplayGroup.
| ERXBatchingDisplayGroup | ( | EOKeyValueUnarchiver | unarchiver | ) | [private] |
Creates a new ERXBatchingDisplayGroup from an unarchiver.
| unarchiver | the unarchiver to construct this display group with |
| int batchCount | ( | ) |
Overridden to return the pre-calculated number of batches
| static Object decodeWithKeyValueUnarchiver | ( | EOKeyValueUnarchiver | unarchiver | ) | [static] |
Decodes an ERXBatchingDisplayGroup from the given unarchiver.
| unarchiver | the unarchiver to construct this display group with |
| NSArray<T> displayedObjects | ( | ) |
Overridden method in order to fetch -only- the rows that are needed. This is different to the editors methods because a WODisplayGroup would always fetch from the start until the end of the objects from the fetch limit.
| Object fetch | ( | ) |
Overridden to fetch only within displayed limits.
| EOFetchSpecification fetchSpecification | ( | ) | [protected] |
Utility to get the fetch spec from the datasource and the filter qualifier.
| NSArray<T> filteredObjects | ( | ) |
Overridden to return allObjects() when batching, as we can't qualify in memory.
| boolean hasMultipleBatches | ( | ) |
Overridden to refetchIfNecessary() first to ensure we get a correct result in cases where this is called before displayedObjects(). See http://issues.objectstyle.org/jira/browse/WONDER-381
| boolean isBatching | ( | ) | [protected] |
Determines if batching is possible.
| boolean isRawRowsForCustomQueries | ( | ) |
Returns whether or not fetch specification with custom queries should use raw rows.
| NSArray<T> objectsInRange | ( | int | start, | |
| int | end | |||
| ) | [protected] |
Utility to fetch the object in a given range.
| start | ||
| end |
| NSArray<String> prefetchingRelationshipKeyPaths | ( | ) |
Returns the prefetching key paths overriding those in the underlying fetch spec.
| void refetch | ( | ) | [protected] |
Utility that does the actual fetching, if a qualifier() is set, it adds it to the dataSource() fetch qualifier.
| void refetchIfNecessary | ( | ) | [protected] |
| int rowCount | ( | ) |
Utility to get at the number of rows when batching.
| Object selectFilteredObjects | ( | ) |
Selects the visible objects, overridden to fetch all objects. Note that this makes sense only when there are only a "few" objects in the list.
| void setCurrentBatchIndex | ( | int | index | ) |
Overriden to clear out our array of fetched objects.
| void setDataSource | ( | EODataSource | eodatasource | ) |
Overridden to set the isBatching flag to true if we have an EODatabaseDataSource.
| void setNumberOfObjectsPerBatch | ( | int | count | ) |
Overriden to clear out our array of fetched objects.
| void setObjectArray | ( | NSArray | objects | ) |
Overridden to update the batch count.
| void setPrefetchingRelationshipKeyPaths | ( | NSArray< String > | prefetchingRelationshipKeyPaths | ) |
Sets the prefetching key paths to override those in the underlying fetch spec.
| prefetchingRelationshipKeyPaths | the prefetching key paths to override those in the underlying fetch spec |
| void setQualifier | ( | EOQualifier | aEoqualifier | ) |
Overridden to trigger a refetch.
| void setRawRowsForCustomQueries | ( | boolean | rawRowsForCustomQueries | ) |
Sets whether or not fetch specification with custom queries should use raw rows. Defaults to true for backwards compatibility.
| rawRowsForCustomQueries | whether or not fetch specification with custom queries should use raw rows |
| void setRowCount | ( | int | rowCount | ) |
Override the number of rows of results (if you can provide a better estimate than the default behavior). If you guess too low, you will never get more than what you set, but if you guess too high, it will adjust. Call with -1 to have the rows counted again.
| rowCount | the number of rows of results |
| void setShouldRememberRowCount | ( | boolean | shouldRememberRowCount | ) |
Set to true to retain the rowCount() after it is determined once for a particular qualifier. Set to false to have rowCount() re-calculated when the batch changes. The default is true.
| shouldRememberRowCount | the shouldRememberRowCount to set |
| void setSortOrderings | ( | NSArray | nsarray | ) |
Overridden to preserve the selected objects.
| boolean shouldRememberRowCount | ( | ) |
true if the rowCount() should be remembered after being determined or false if rowCount() should be re-calculated when the batch changes | void updateBatchCount | ( | ) | [protected] |
| void updateDisplayedObjects | ( | ) |
int _batchCount [protected] |
total number of batches
NSArray<T> _displayedObjects [protected] |
cache for the displayed objects
Boolean _isBatching [protected] |
cache batching flag
NSArray<String> _prefetchingRelationshipKeyPaths [protected] |
boolean _rawRowsForCustomQueries = true [private] |
int _rowCount = -1 [protected] |
boolean _shouldRememberRowCount = true [protected] |
final Logger log = Logger.getLogger(ERXBatchingDisplayGroup.class) [static, private] |
Logging support
1.5.8