Property :: cursorCopy - Create copy for property handle
The function returns a property handle with a cursor copy of the handle passed in cProperty (see also use() ) . In order to obtain a property handle sharing the cursor, use() should be called. When a filter condition had been set for cProperty , the filter condition is copied as well. When an instance had been located in the original property handle, the cursor copy is located. The cursor copy is unselected, i.e. selection is not copied from the source.
When the property handle passed in cProperty is not valid, the property handle remains invalid.
// fragment
.... function ( Property &person ) {
Property my_cursor(person.cursorCopy());
if ( my_cursor.located() )
my_cursor.get(); // select located instance
}
Copy
A property handle refers to a (usually) opened property. Invalid properties may cause an exception.
Implementation details
The function creates a copy of the property handle. A copy of a property handle has its own cursor but refers to the same data source (collection, instance, value).