Session.GetObjectsAsync(XPClassInfo, CriteriaOperator, SortingCollection, Int32, Int32, Boolean, Boolean, CancellationToken) Method
Asynchronously retrieves persistent objects from specified queries.
Namespace: DevExpress.Xpo
Assembly: DevExpress.Xpo.v24.2.dll
#Declaration
public Task<ICollection> GetObjectsAsync(
XPClassInfo classInfo,
CriteriaOperator criteria,
SortingCollection sorting,
int skipSelectedRecords,
int topSelectedRecords,
bool selectDeleted,
bool force,
CancellationToken cancellationToken = default(CancellationToken)
)
#Parameters
Name | Type | Description |
---|---|---|
class |
XPClass |
An XPClass |
criteria | Criteria |
A Criteria |
sorting | Sorting |
A Sorting |
skip |
Int32 | An integer value which specifies the number of objects to exclude when populating the collection. |
top |
Int32 | An integer value which specifies the maximum number of returned objects. |
select |
Boolean | true, to include the persistent objects marked as deleted into the collection; otherwise, false. |
force | Boolean | true, to reload the objects from a data store; otherwise, false. |
#Optional Parameters
Name | Type | Default | Description |
---|---|---|---|
cancellation |
Cancellation |
null | A Cancellation |
#Returns
Type | Description |
---|---|
Task<ICollection> | A Task that returns a collection of obtained persistent objects. |
#Remarks
This member supports the internal infrastructure and is not intended to be used directly from your code. To asynchronously get objects from a session, call the LoadAsync method of the XPCollection or XPView component.