Solved

Deep cloning

Posted on 2007-04-04
3
322 Views
Last Modified: 2013-11-26
I have an Object which inherits from system.collections.collectionbase which needs to be deep cloned.
public class a
inherits system.collections.collectionbase
end class

How do i insure that a new copy of the collection is created in the cloned object b.
0
Comment
Question by:visualbasic
3 Comments
 
LVL 22

Accepted Solution

by:
Bill-Hanson earned 50 total points
ID: 18851422
I think you need to iterate over the collection and copy it to the cloned class.  I don't think there is any mechanism out there that will do it automatically.
0
 

Author Comment

by:visualbasic
ID: 18856522
Ya - I came to the same conclusion
Thanks anyway
0
 

Expert Comment

by:SGTOBIN
ID: 22117082
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The object model of .Net can be overwhelming at times – so overwhelming that quite trivial tasks often take hours of research. In this case, the task at hand was to populate the datagrid from SQL Server database in Visual Studio 2008 Windows applica…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question