|
Project Wonder 5.0 | |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecter.extensions.eof.ERXBatchFetchUtilities
public class ERXBatchFetchUtilities
ERXBatchFetchUtilities provides a collection of methods to support efficiently batch fetching arbitrarily deep keypaths on EOs.
Constructor Summary | |
---|---|
ERXBatchFetchUtilities()
|
Method Summary | |
---|---|
static void |
batchFetch(com.webobjects.eocontrol.EOEnterpriseObject sourceObject,
com.webobjects.foundation.NSArray keypaths,
boolean skipFaultedSourceObjects)
Shortcut for batch fetching a single source object |
static void |
batchFetch(com.webobjects.foundation.NSArray<? extends com.webobjects.eocontrol.EOEnterpriseObject> sourceObjects,
ERXKey<?>... keys)
Batch key the list of keys from the given source objects. |
static void |
batchFetch(com.webobjects.foundation.NSArray sourceObjects,
com.webobjects.foundation.NSArray keypaths)
Defaults skipFaultedSourceObjects to false for backwards compatibility |
static void |
batchFetch(com.webobjects.foundation.NSArray sourceObjects,
com.webobjects.foundation.NSArray keypaths,
boolean skipFaultedSourceObjects)
Batch fetch relationships specified by keypaths for sourceObjects . |
static void |
batchFetch(com.webobjects.foundation.NSArray sourceObjects,
com.webobjects.foundation.NSArray keypaths,
boolean skipFaultedSourceObjects,
int batchSize)
Overloads batchFetch(NSArray, NSArray, boolean) to batch through the NSArray of sourceObjects batchSize at a time. |
static void |
batchFetch(com.webobjects.foundation.NSArray sourceObjects,
java.lang.String keypath)
Shortcut for batch fetching a single keypath. |
static void |
batchFetch(com.webobjects.foundation.NSArray sourceObjects,
java.lang.String keypath,
boolean skipFaultedSourceObjects)
Shortcut for batch fetching a single keypath. |
static com.webobjects.foundation.NSArray |
batchFetchAndRetrieve(com.webobjects.foundation.NSArray sourceObjects,
java.lang.String keypath)
Shortcut for batch fetching a single keypath and returns returns the fetched values. |
static com.webobjects.foundation.NSArray |
batchFetchAndRetrieve(com.webobjects.foundation.NSArray sourceObjects,
java.lang.String keypath,
boolean skipFaultedSourceObjects)
Shortcut for batch fetching a single keypath and returns returns the fetched values. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ERXBatchFetchUtilities()
Method Detail |
---|
public static void batchFetch(com.webobjects.foundation.NSArray sourceObjects, com.webobjects.foundation.NSArray keypaths)
sourceObjects
- the array of source object to fault keypaths on.keypaths
- the array of keypaths to faultbatchFetch(NSArray, NSArray, boolean)
public static void batchFetch(com.webobjects.foundation.NSArray<? extends com.webobjects.eocontrol.EOEnterpriseObject> sourceObjects, ERXKey<?>... keys)
sourceObjects
- the array of source object to fault keypaths on.keys
- the array of ERXKeys to faultpublic static void batchFetch(com.webobjects.eocontrol.EOEnterpriseObject sourceObject, com.webobjects.foundation.NSArray keypaths, boolean skipFaultedSourceObjects)
sourceObject
- source object to fault keypaths on.keypaths
- the array of keypaths to faultskipFaultedSourceObjects
- if true, all source objects that already have their relationships faulted will be skippedbatchFetch(NSArray, NSArray, boolean)
public static void batchFetch(com.webobjects.foundation.NSArray sourceObjects, java.lang.String keypath)
sourceObjects
- the array of source object to fault keypaths on.keypath
- the keypath to faultbatchFetch(NSArray, NSArray, boolean)
public static void batchFetch(com.webobjects.foundation.NSArray sourceObjects, java.lang.String keypath, boolean skipFaultedSourceObjects)
sourceObjects
- the array of source object to fault keypaths on.keypath
- the keypath to faultskipFaultedSourceObjects
- if true, all source objects that already have their relationships faulted will be skippedbatchFetch(NSArray, NSArray, boolean)
public static com.webobjects.foundation.NSArray batchFetchAndRetrieve(com.webobjects.foundation.NSArray sourceObjects, java.lang.String keypath)
sourceObjects
- the array of source object to fault keypaths on.keypath
- the keypath to faultbatchFetch(NSArray, NSArray, boolean)
public static com.webobjects.foundation.NSArray batchFetchAndRetrieve(com.webobjects.foundation.NSArray sourceObjects, java.lang.String keypath, boolean skipFaultedSourceObjects)
sourceObjects
- the array of source object to fault keypaths on.keypath
- the keypath to faultskipFaultedSourceObjects
- if true, all source objects that already have their relationships faulted will be skippedbatchFetch(NSArray, NSArray, boolean)
public static void batchFetch(com.webobjects.foundation.NSArray sourceObjects, com.webobjects.foundation.NSArray keypaths, boolean skipFaultedSourceObjects)
This method will use EODatabaseContext.batchFetchRelationship to efficiently fetch like relationships for many objects in as few as one database round trip per relationship.
For example, if fetching from Movie entities, you might specify paths of the form: ("directors","roles.talent", "plotSummary"). This works much like prefetching with fetch specifications, however this implementation is able to work around inheritance where prefetching fails.
sourceObjects
- the array of source objects to fault keypaths on.keypaths
- the array of keypaths to faultskipFaultedSourceObjects
- if true, all source objects that already have their relationships faulted will be skippedpublic static void batchFetch(com.webobjects.foundation.NSArray sourceObjects, com.webobjects.foundation.NSArray keypaths, boolean skipFaultedSourceObjects, int batchSize)
sourceObjects
- keypaths
- skipFaultedSourceObjects
- batchSize
- batchFetch(NSArray, NSArray, boolean)
|
Last updated: Tue, Feb 21, 2017 05:45 PM CET | |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |