TD-24286: UDV cloning

Missing or incomplete OpenText Gupta product features? Discuss it here!
Dave Rabelink
Founder/Site Admin
Founder/Site Admin
Netherlands
Posts: 1313
Joined: 24 Feb 2017, 09:12
Location: Gouda, The Netherlands

TD-24286: UDV cloning

Post by Dave Rabelink » 10 Dec 2018, 11:48

Feature request.

OTCS Ticket 4025633 : TD-24286: Feature request: clone UDV's

Allow cloning a UDV to a new UDV object.

To copy one UDV to another (by value, not by reference) developers need to create class functions to copy all the instance variables to a new UDV object.

Code: Select all

uMyUDV.CopyTo( uNewUDV )
Issue with this:

- The Copy function is manual work. Forgetting an instance to copy, results in issues
- Changing UDV afterwards by adding new instance vars also needs revisiting the copy functions. Forget is easily done
- Performance: each variable needs to be copied one by one in SAL code

A simple way to clone a UDV to a new UDV object using SAL.

Examples:

Code: Select all

Call SalUDVClone( uMyUDV, uMyNewUDV )
(or similar function)

The clone should copy all instance variables, even when they are arrays and also copies nested UDV's (arrays).
The clone must also copy all base class instances when present.
Regards,
Dave Rabelink

Image
Articles and information on Team Developer Tips & Tricks Wiki
Download samples, documents and resources from TD Sample Vault
Videos on TDWiki YouTube Channel

EwaldP
Austria
Posts: 145
Joined: 07 Mar 2017, 08:00
Location: Austria

Re: TD-24286: UDV cloning

Post by EwaldP » 10 Dec 2018, 13:14

+1
Ewald P. Palmetshofer
EDV-Hausleitner GmbH
4020 Linz
www.edv-hausleitner.at

H3PO4
Germany
Posts: 60
Joined: 10 Mar 2017, 07:53
Location: Rohlstorf, Germany

Re: TD-24286: UDV cloning

Post by H3PO4 » 19 Dec 2018, 10:31

+1

Igor Ivanovic
Site Admin
Site Admin
Croatia
Posts: 830
Joined: 05 Mar 2017, 12:37
Location: Zagreb, Croatia

Re: TD-24286: UDV cloning

Post by Igor Ivanovic » 19 Dec 2018, 13:03

+10
Igor Ivanovic
Image

Return to “Enhancement suggestions”

Who is online

Users browsing this forum: [Ccbot] and 0 guests