25.01.2015 Views

Using Caché Objects - InterSystems Documentation

Using Caché Objects - InterSystems Documentation

Using Caché Objects - InterSystems Documentation

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

%OnConstructClone<br />

Its syntax is:<br />

ReturnValue %OnClose()<br />

where:<br />

ReturnValue<br />

A %Status code. The return value is not used by %Close.<br />

This method is available to the %Library.RegisteredObject class and its subclasses.<br />

20.5 %OnConstructClone<br />

This instance method is called by the %ConstructClone method immediately after the<br />

structures have been allocated for the cloned object and all the data has been copied into it.<br />

The method allows you to perform any additional actions related to the cloned object, such<br />

as taking out a lock or resetting any of the clone's property values.<br />

Its syntax is:<br />

ReturnValue %OnConstructClone(Object As %RegisteredObject, Deep As<br />

%Boolean)<br />

where:<br />

ReturnValue<br />

Object<br />

Deep<br />

A %Status code, where an error code prevents the clone from being<br />

created.<br />

The OREF of the object that was cloned.<br />

How “deep” the cloning process is, where 0 specifies that the clone<br />

points to the same related objects as the original; 1 causes objects<br />

related to the object being cloned to also be cloned, so that the clone<br />

gets its own set of related objects.<br />

This method is available to the %Library.RegisteredObject class and its subclasses.<br />

<strong>Using</strong> <strong>Caché</strong> <strong>Objects</strong> 173

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!