deep

How to deep clone interconnected objects in C#?

What is the best way to deep clone an interconnected set of objects? Example: class A { B theB; // optional // ... } class B { A theA; // optional // ... } class Container { A[] a; B[] b; } The obvious thing to do is walk the objects and deep clone everything as I come to it. This creates a problem however -...

.Net Deep cloning - what is the best way to do that?

Hi Guys, I need to perform deep cloning on my complex object model. What do you think is the best way to do that in .Net? I thought about serializing / Deserializing no need to mention that memberwiseClone is not good enough. thanks a lot, Adi Barda ...

Clone (deep copy) Entity LINQ

Hi, I would like to deep copy an Entity and I am looking for the best way to do it. I am also concerned about performances. I plan to have all my entities implementing ICloneable where Clone() will basically shadow copy and Clone all references. For instance: [DataContract()] class MyEntity { public int id; public strin...

Issue uploading images for deep zoom

I have created a WPF application that basically converts a file from tiff/pdf to png and then dynamically splits the image into tiles then uploads them to the db. I am running into a problem where the 2nd level of tiles upload as black images...anybody see this before and maybe have an idea of what's going on? can post code if needed.....

for loops execution

can the following loop be executed for(j=0;i=len-1;i>=0;i--;j++) and if yes please tell me how the execution procedure? ...

How do I copy an arraylist from one class to another in Java?

I understand that in order to copy an arraylist and have two lists independent of one another you must use a deep copy (copying the objects from one list to another not just the references), however is there a way this can be done cross-class? For example; I am calling Class2 from Class1. In Class2 objects are added to an ArrayList of c...

how to deep copy a class without marking it as serializable

I came across many questions on deep copy but non of them helped me I have a class say class A { ... public List<B> ListB; .... } where B is again another class which inturn may inherit/contain some other classes Take this scenario A is a very huge class and contain many reference types I can not mark B as serializable ...

Deep Zoom Composer performance issues

I've been using the DZC for some time and was happy with it using the deepzoom images in my web pages. I always needed to compose hundreds of images into single grids and export as a sinle image. Lately my image number claimed to over 2,000 of 1MB images and here the DZC stopped working. It takes 15 hours to export and often the proces...

Creating an easy to maintain copy constructor

Hi, Consider the following class: class A { char *p; int a, b, c, d; public: A(const &A); }; In the above I have to define a copy constructor in order to do a deep copy of "p". This has two issues: most of the fields should simply copied. Copying them one by one is ugly and error prone. the more important problem is that whene...

Deep Copy [] and ArrayList Java

Hello, I want to make a Deep Copy of some Object[] and ArrayList How can i do that (without looping , and calling clone) There aren't standard utils for doing this? Thanks João ...

value transfer from a list to another

Hallo, I have a problem with value transfer from a list to another in VB2008. I have 2 lists of string with same number of member that reference to their object-collections separately. I want to overwrite memory slots of list1 with the values of list2 without creating new memory slots. How can I do these? Thx. Lert ...

Deep Cloning in java - Cloning only objects that are being constructed(new)

Problem for me is to implement clone for an object. This object A has it's members object B, which were not created by A. I want to clone A such that only object's created during construction of A to be cloned. The objects which were either passed as reference in A or A's objects or A's object's object not to be cloned. They should only ...

Deep cloning of an object to a similar one in a different namespace in java

I have 2 web services declared in 2 different packages in java package com.HelloWorld @WebService(targetNamespace="http://www.xyz.com/Hello") @SOAPBinding(parameterStyle = ParameterStyle.WRAPPED, style = Style.DOCUMENT, use = Use.LITERAL) { public class Hello { @WebMethod @WebResult(name="SayHelloResult", targetNamespace="h...

exception saving a deep cloned C# nhibernate object

Hi, I'm having a hard time trying to clone a complex C# object persisted with NHibernate. The object has a deeply nested structure with lots of children objects organized in ILists, but it is completely self contained, without references to other persisted entities. What I've tried to do so far is to deep clone the object through seriali...

Deep combine NSDictionaries

I need to merge two NSDictionarys into one provided that if there are dictionaries within the dictionaries, they are also merged. More or less like jQuery's extend function. ...