Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

30 lines (22 sloc) 0.56 kb
//
// NSArrayAdditions.m
// JobStairs
//
// Created by Jens Kohl on 23.02.10.
// Copyright 2010 Jens Kohl. All rights reserved.
//
#import "NSArrayAdditions.h"
@implementation NSArray (JKAdditions)
- (NSString*)asStringWithDelimiter:(NSString *)delimiter {
NSMutableString *string = [NSMutableString string];
NSUInteger countdown = [self count];
for (id item in self) {
[string appendString:[item description]];
countdown--;
if (countdown > 0) {
[string appendString:delimiter];
}
}
return [NSString stringWithString:string];
}
@end
Jump to Line
Something went wrong with that request. Please try again.