Oolite 1.91.0.7646-241128-10e222e
Loading...
Searching...
No Matches
NSArray(OldSchoolPropertyListWriting) Category Reference

#include <OldSchoolPropertyListWriting.h>

+ Inheritance diagram for NSArray(OldSchoolPropertyListWriting):
+ Collaboration diagram for NSArray(OldSchoolPropertyListWriting):

Instance Methods

(NSString *) - oldSchoolPListFormatWithIndentation:errorDescription: [implementation]
 
- Instance Methods inherited from <OldSchoolPropertyListWriting>

Detailed Description

Definition at line 52 of file OldSchoolPropertyListWriting.h.

Method Documentation

◆ oldSchoolPListFormatWithIndentation:errorDescription:

- (NSString *) oldSchoolPListFormatWithIndentation: (unsigned) inIndentation
errorDescription: (NSString **) outErrorDescription 
implementation

Reimplemented from <OldSchoolPropertyListWriting>.

Definition at line 325 of file OldSchoolPropertyListWriting.m.

184 :(unsigned)inIndentation errorDescription:(NSString **)outErrorDescription
185{
186 NSMutableString *result;
187 NSUInteger i, count;
188 id object;
189
190 result = [NSMutableString string];
191
192 [result appendString:@"("];
193
194 count = [self count];
195 AppendNewLineAndIndent(result, inIndentation + 1);
196
197 for (i = 0; i != count; ++i)
198 {
199 if (0 != i)
200 {
201 [result appendString:@","];
202 AppendNewLineAndIndent(result, inIndentation + 1);
203 }
204
205 object = [self objectAtIndex:i];
206 if (![object conformsToProtocol:@protocol (OldSchoolPropertyListWriting)])
207 {
208 if (nil != object && NULL != outErrorDescription)
209 {
210 *outErrorDescription = [NSString stringWithFormat:@"non-plist object in dictionary"];
211 }
212 return nil;
213 }
214
215 object = [object oldSchoolPListFormatWithIndentation:inIndentation + 1 errorDescription:outErrorDescription];
216 if (nil == object) return nil;
217 [result appendString:object];
218 }
219
220 AppendNewLineAndIndent(result, inIndentation);
221 [result appendString:@")"];
222 return result;
223}
unsigned count
return nil
static void AppendNewLineAndIndent(NSMutableString *ioString, unsigned indentDepth)

The documentation for this category was generated from the following files: