deep-copy
Making a copy of an object of abstract base class
If I have a pointer to an object that derives from an abstract base class (so I cannot create an new object of that class), and I wish to make a deep copy of said object开发者_Go百科, is there a more[详细]
2023-02-05 16:35 分类:问答Alternative of strcpy in c++
In C i used strcpy to make a deep copy of a string, but is it still \'fi开发者_运维技巧ne\' to use strcpy in C++ or are there better alternatives which i should use instead ? I put this in the comment[详细]
2023-02-05 14:40 分类:问答Invert linear linked list
a linear linked list is a set of nodes. This is how a node is defined (to keep it easy we do not distinguish between node an list):[详细]
2023-02-04 11:40 分类:问答Deep copy of linear linked list
I have a linear linked list that consists of nodes: class Node{ Object data; Node link; public Node(Object pData, Node pLink){[详细]
2023-02-04 10:47 分类:问答Deep copy of a record with R1:=R2, or Is there good way to implement NxM matrix with record?
I\'m implementing a N x M matrix (class) with a record and an internal dynamic array like below. TMat = record[详细]
2023-01-29 01:19 分类:问答Deep copy of List<T>
I\'m trying to make a deep copy of a generic list, and am wondering if there is any other way then creating the copying method and actually copying over each member one at a time. I have a class that[详细]
2023-01-26 03:38 分类:问答Copy nested objects in Java
So I have the following classes: class A{ public A(int n1){ n=n1; } int n; } class B extends A{ public B(int n2){[详细]
2023-01-25 23:13 分类:问答Proper way to deep copy with copy constructor instead of Object.clone
I have some code that performs a deep copy using Object.clone, but I\'m trying to rewrite it using the more \"acceptable\" copy constructor technique. Below are two simple examples of what I\'m trying[详细]
2023-01-25 16:36 分类:问答How to make a deep copy of an InputStream in Java [closed]
Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post.[详细]
2023-01-23 09:23 分类:问答What do I put in the visit dict passed to my user-defined __deepcopy__ function?
I need to define开发者_开发知识库 my own deepcopy function for one of my classes. The documentation says that the function __deepcopy__() is passed a memo dictionary for tracking which objects have al[详细]
2023-01-23 07:52 分类:问答