Re: Deleting from TableView and MutableArray
Re: Deleting from TableView and MutableArray
- Subject: Re: Deleting from TableView and MutableArray
- From: Pandaa <email@hidden>
- Date: Wed, 14 Apr 2004 19:02:34 +0200
2004-04-14 kl. 01.15 skrev Carl Sziebert:
Hi all:
I am rather new to objective-c and am having trouble figuring out the
correct way to do the following:
My application has a table view that displays items which are a subset
of a master mutable array. The issue that I am attempting to solve is
when I choose an item in the table view and want to delete it. It
should be removed from both the table view and the master array.
Any advice is greatly appreciated.
Since deleting objects in arrays is O(n), it will do fine to simply
search the master array linearly for the object to be deleted. Try
using indexOfObject:, or removeObject: directly.
. . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . .
. . . . earth water fire air software - the five elements . . . .
. . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . .
. email@hidden . . www.synapticpulse.net .
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.