[Seaside] How generate ID
Philippe Marschall
philippe.marschall at gmail.com
Sun Dec 30 07:50:57 UTC 2007
2007/12/29, Tom Phoenix <rootbeer at redcat.com>:
> On Dec 29, 2007 12:53 PM, Tom Phoenix <rootbeer at redcat.com> wrote:
>
> > MyClass class>>initialize
> > super initialize.
> > LastID := ifNil: [ LastID := 0 ] .
>
> Oops -- Omit that first assignment operator.
>
> LastID ifNil: [ LastID := 0 ].
Just remember stuff like this is not thread-safe, the same is true for
incrementing too.
Cheers
Philippe
> --Tom Phoenix
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
More information about the seaside
mailing list