Monotone-Parent: 9bf1b57a27d30984eb23f37b8cfbe075869b047a

Monotone-Revision: 15503fe623be16f680136363d33fa6452249289a

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2009-07-23T17:32:09
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2009-07-23 17:32:09 +00:00
parent da6af09c45
commit b35388fd4e
3 changed files with 27 additions and 6 deletions
+19 -6
View File
@@ -115,12 +115,8 @@
flattenedArray = [NSMutableArray array];
objects = [self objectEnumerator];
currentObject = [objects nextObject];
while (currentObject)
{
[flattenedArray addObjectsFromArray: currentObject];
currentObject = [objects nextObject];
}
while ((currentObject = [objects nextObject]))
[flattenedArray addObjectsFromArray: currentObject];
return flattenedArray;
}
@@ -196,6 +192,23 @@
return response;
}
- (NSArray *) trimmedComponents
{
NSMutableArray *newComponents;
NSString *currentString;
unsigned int count, max;
max = [self count];
newComponents = [NSMutableArray arrayWithCapacity: max];
for (count = 0; count < max; count++)
{
currentString = [[self objectAtIndex: count] stringByTrimmingSpaces];
[newComponents addObject: currentString];
}
return newComponents;
}
@end
@implementation NSMutableArray (SOGoArrayUtilities)