CellML Discussion List

Text archives Help


[cellml-discussion] CellML API: clone operation?


Chronological Thread 
  • From: matt.halstead at auckland.ac.nz (Matt Halstead)
  • Subject: [cellml-discussion] CellML API: clone operation?
  • Date: Mon, 24 Apr 2006 15:43:24 +1200

I don't have a problem with that.


On 24/04/2006, at 1:08 PM, Andrew Miller wrote:

> Hi all,
>
> It seems that we never defined a clone operation in the CellML API,
> and it seems
> that this would be very useful.
>
> We do have a getAlternateVersion(), which performs a deep clone and
> changes
> namespaces at the same time, which could be (ab/re-)used to perform
> clones, but
> it seems that we still should have a pure clone() on model(or
> perhaps better,
> CellMLElement). It could take a deep parameter, like DOM nodes do...
>
> /**
> * Clones a CellMLElement, and optionally all children.
> * This will not clone the contents of imported models.
> * @param deep If false, only clones the element. It will then have
> no children.
> * If true, clones the element, and its children, which
> are added
> * into the new element.
> */
> CellMLElement clone(bool deep);
>
> Opinions?
>
> Best regards,
> Andrew Miller
>
>
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
> _______________________________________________
> cellml-discussion mailing list
> cellml-discussion at cellml.org
> http://www.cellml.org/mailman/listinfo/cellml-discussion





Archive powered by MHonArc 2.6.18.

Top of page