From ed4a264108d52beaf5ab6afcb4980d5766ddb4e7 Mon Sep 17 00:00:00 2001 From: Daniel Stolzenberg Date: Tue, 26 Oct 2010 12:24:20 +0200 Subject: [PATCH] removed duplicated (and buggy) implementations of "valueForKey:" and "setValue:forKey:" in CPArray.j --- Foundation/CPArray.j | 32 -------------------------------- 1 file changed, 32 deletions(-) diff --git a/Foundation/CPArray.j b/Foundation/CPArray.j index ed97d6ea1..e912d1d27 100755 --- a/Foundation/CPArray.j +++ b/Foundation/CPArray.j @@ -972,38 +972,6 @@ CPEnumerationReverse = 1 << 1; return array; } -// Key value coding -/*! - Sets the key-value for each element in the array. - @param aValue the value for the coding - @param aKey the key for the coding -*/ -- (void)setValue:(id)aValue forKey:(CPString)aKey -{ - var i = 0, - count = [self count]; - - for (; i < count; ++i) - [self[i] setValue:aValue forKey:aKey]; -} - -/*! - Returns the value for \c aKey from each element in the array. - @param aKey the key to return the value for - @return an array of containing a value for each element in the array -*/ -- (CPArray)valueForKey:(CPString)aKey -{ - var i = 0, - count = [self count], - array = []; - - for (; i < count; ++i) - array.push([self[i] valueForKey:aKey]); - - return array; -} - // Copying arrays /*!