LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
copyElement.m
1function clone = copyElement(self)
2% CLONE = COPYELEMENT()
3
4% Make a shallow copy of all properties
5clone = copyElement@Copyable(self);
6% Make a deep copy of each handle
7for i=1:length(self.classes)
8 clone.classes{i} = self.classes{i}.copy;
9end
10% Make a deep copy of each handle
11for i=1:length(self.nodes)
12 clone.nodes{i} = self.nodes{i}.copy;
13 if isa(clone.nodes{i},'Station')
14 clone.stations{i} = clone.nodes{i};
15 end
16 clone.connections = self.connections;
17end
18end
Definition mmt.m:92