with Deep Create
Set a flag to mark this entity to be created by a subsequent DataService.activateDraft call, or by a DataService.createEntity call that should perform a deep create.
Set {@link com.sap.cloud.mobile.kotlin.odata.EntityValue#cascadePaths EntityValue.cascadePaths} to paths if paths is non-empty, otherwise set {@link com.sap.cloud.mobile.kotlin.odata.EntityValue#cascadePaths EntityValue.cascadePaths} to null.
If paths is empty, the subsequent deep create should include composition children (recursively) which are specified with on-delete-cascade.
- Example using proxy classes:
open fun deepCreateExample(): kotlin.Unit { val service = this.service; val customer = Customer(); customer.companyName = "Enterprise Inc."; customer.contactName = "LeVar Burton"; val order1 = Order(); val order2 = Order(); customer.bindEntity(order1, Customer.orders); customer.bindEntity(order2, Customer.orders); service.createEntity(customer.withDeepCreate()); }
Return
This entity instance.
Parameters
paths
List of property paths (usually {@link com.sap.cloud.mobile.kotlin.odata.Property} instances).