Skip to main content
.NET 6.0+

Session.IsObjectToSave(Object, Boolean) Method

Indicates whether the specified object is saved in the transaction currently in progress or in any of its parent transaction (optionally).

Namespace: DevExpress.Xpo

Assembly: DevExpress.Xpo.v23.2.dll

NuGet Package: DevExpress.Xpo

Declaration

public virtual bool IsObjectToSave(
    object theObject,
    bool includeParent
)

Parameters

Name Type Description
theObject Object

The persistent object to test.

includeParent Boolean

true to check whether the persistent object is saved in the parent transaction(s); otherwise, false.

Returns

Type Description
Boolean

true if the specified object is saved in the transaction currently in progress or in any of its parent transaction (optionally); otherwise, false.

Remarks

This method indicates whether the specified object is saved only in the transaction currently in progress. It is overridden in the NestedUnitOfWork class to check parent transactions for the specified object.

To get a collection of persistent objects that are saved in the transaction currently in progress, use the Session.GetObjectsToSave method.

For general information on saving persistent objects, see Persisting Objects.

See Also