Re: Clone an object

2009-12-31 Thread Jenda Krynicky
From: Erez Schatz > Shlomi, please stop correcting the English of those who post here. > It's rude, nope > off-topic, maybe > and unimportant. Not at all. Being able to express your needs/questions clearly is quite important. Jenda = je...@krynicky.cz === http://Jenda.Krynicky.cz ===

Re: Clone an object

2009-12-31 Thread Jenda Krynicky
- You might, but what about others? You do want others to read your messages and help you with your questions, don't you? - But I remember what I wrote last time so I don't have to read it. - 'cause it's all backwards! - Why is that? - Because it's hard to read. - Why? - Please do not top post. F

Re: Clone an object

2009-12-29 Thread C.DeRykus
On Dec 28, 3:54 am, jeffp...@netzero.net (Jeff Peng) wrote: > Uri Guttman: > > > > > and i bet you really don't need this but you just think you do. > > why not? > I did have used object clone, like a ruby one: > >  > class Myclass >  > end > => nil > >  > x=Myclass.new > => # > >  > y=x.clone > =>

Re: Clone an object

2009-12-28 Thread Erez Schatz
Shlomi, please stop correcting the English of those who post here. It's rude, off-topic, and unimportant. This isn't a language mailing list and you are not its chief linguistic officer. I understand you take pride in your English, since you are not a native speaker, but that has nothing to do with

Re: Clone an object

2009-12-28 Thread Christoph Friedrich
Thank you ^^ Shlomi Fish schrieb: Hi Christoph! This message was sent in private and it contains corrections to your English. On Monday 28 Dec 2009 14:53:04 Christoph Friedrich wrote: I know that there are many Sudoku solver over the internet. s/solver/solvers/ . s/over the/on the/

Re: Clone an object

2009-12-28 Thread Shlomi Fish
Hi Christoph! This message was sent in private and it contains corrections to your English. On Monday 28 Dec 2009 14:53:04 Christoph Friedrich wrote: > I know that there are many Sudoku solver over the internet. s/solver/solvers/ . s/over the/on the/ > But than I has no chance of learning perl

Re: Clone an object

2009-12-28 Thread Uri Guttman
> "JP" == Jeff Peng writes: JP> Uri Guttman: >> >> and i bet you really don't need this but you just think you do. JP> why not? JP> I did have used object clone, like a ruby one: huh?? >> class Myclass >> end JP> => nil >> x=Myclass.new JP> => # >> y=x.clone JP>

Re: Clone an object

2009-12-28 Thread Randal L. Schwartz
> "Christoph" == Christoph Friedrich > writes: Christoph> My Big Problem is that I must copy an object to do a backtracking Christoph> method (I am going to develop a sudoku solver). Then your object should know how to clone itself. -- Randal L. Schwartz - Stonehenge Consulting Servic

Re: Clone an object

2009-12-28 Thread Shlomi Fish
Hi Christoph. On Monday 28 Dec 2009 14:53:04 Christoph Friedrich wrote: > I know that there are many Sudoku solver over the internet. > But than I has no chance of learning perl and learn some of the > algorhytms ^^ > So it's an exercise for learning. I see. If you would like to work on somethi

Re: Clone an object

2009-12-28 Thread Christoph Friedrich
I know that there are many Sudoku solver over the internet. But than I has no chance of learning perl and learn some of the algorhytms ^^ Shlomi Fish schrieb: Hi Christoph! On Monday 28 Dec 2009 13:11:17 Christoph Friedrich wrote: My Big Problem is that I must copy an object to do a backt

Re: Clone an object

2009-12-28 Thread Erez Schatz
On 28/12/2009, Shlomi Fish wrote: > Hi Christoph! > > On Monday 28 Dec 2009 13:11:17 Christoph Friedrich wrote: >> My Big Problem is that I must copy an object to do a backtracking method >> (I am going to develop a sudoku solver). >> > Moreover, I should note that there are plenty of Sudoku solv

Re: Clone an object

2009-12-28 Thread Jeff Peng
Uri Guttman: and i bet you really don't need this but you just think you do. why not? I did have used object clone, like a ruby one: > class Myclass > end => nil > x=Myclass.new => # > y=x.clone => # > x.object_id => -605921708 > y.object_id => -605931318 The object was cloned, they b

Re: Clone an object

2009-12-28 Thread Shlomi Fish
Hi Christoph! On Monday 28 Dec 2009 13:11:17 Christoph Friedrich wrote: > My Big Problem is that I must copy an object to do a backtracking method > (I am going to develop a sudoku solver). > Well, you can always deep copy the object state, if you are sure it is self- contained. (Using Storable'

Re: Clone an object

2009-12-28 Thread Christoph Friedrich
My Big Problem is that I must copy an object to do a backtracking method (I am going to develop a sudoku solver). Uri Guttman schrieb: "CF" == Christoph Friedrich writes: CF> I have searched the internet but didn't found a good answer. CF> How do I clone a Perl Object? CF

Re: Clone an object

2009-12-28 Thread Shlomi Fish
Hi Christoph! On Monday 28 Dec 2009 12:04:32 Christoph Friedrich wrote: > Hello, > > I have searched the internet but didn't found a good answer. > How do I clone a Perl Object? > > For example like this: > > $a = My::Object->new(); > $b = $a->clone(); > > Where $b is an exact copy of $a but i

Re: Clone an object

2009-12-28 Thread Philip Potter
2009/12/28 Philip Potter : > If you want to clone an object from a library > provided by someone else, you have to read its documentation and find > a clone object. This should be a clone method, of course. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail

Re: Clone an object

2009-12-28 Thread Philip Potter
2009/12/28 Christoph Friedrich : > I have searched the internet but didn't found a good answer. > How do I clone a Perl Object? > > For example like this: > > $a = My::Object->new(); > $b = $a->clone(); > > Where $b is an exact copy of $a but in its own memory. You call the function that the objec

Re: Clone an object

2009-12-28 Thread Uri Guttman
> "CF" == Christoph Friedrich writes: CF> I have searched the internet but didn't found a good answer. CF> How do I clone a Perl Object? CF> For example like this: CF> $a = My::Object->new(); CF> $b = $a->clone(); the answer is you can't in the general case. only the class should