XPCollection(PersistentCriteriaEvaluationBehavior, Session, XPClassInfo, CriteriaOperator, Boolean) Constructor
Initializes a new instance of the XPCollection class with specified settings.
Namespace: DevExpress.Xpo
Assembly: DevExpress.Xpo.v24.2.dll
NuGet Package: DevExpress.Xpo
#Declaration
public XPCollection(
PersistentCriteriaEvaluationBehavior criteriaEvaluationBehavior,
Session session,
XPClassInfo objType,
CriteriaOperator condition,
bool selectDeleted
)
#Parameters
Name | Type | Description |
---|---|---|
criteria |
Persistent |
A Persistent |
session | Session | The Session that will be used to load and save persistent objects. |
obj |
XPClass |
The persistent class’s metadata information of objects to include into the collection. |
condition | Criteria |
The Criteria |
select |
Boolean | true if objects marked as deleted are loaded to the collection from a data store; otherwise, false. |
#Remarks
Note that when an XPCollection is created using a constructor with the criteriaEvaluationBehavior parameter, the collection is loaded immediately and its XPBaseCollection.LoadingEnabled property is automatically set to false. After that, the collection cannot be reloaded using the XPBaseCollection.Reload method, since object loading is disabled.