* Source/NSXMLDocument.m: Implement XMLStringWithOptions:

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@34407 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Gregory John Casamento 2012-01-03 19:30:03 +00:00
parent c7088ba09c
commit aa8a33f26c
2 changed files with 18 additions and 0 deletions

View file

@ -1,3 +1,7 @@
2012-01-03 14:22-EST Gregory John Casamento <greg.casamento@gmail.com>
* Source/NSXMLDocument.m: Implement XMLStringWithOptions:
2012-01-03 13:03-EST Gregory John Casamento <greg.casamento@gmail.com>
* Headers/Foundation/NSXMLElement.h

View file

@ -282,6 +282,20 @@
return NO;
}
- (NSString *) XMLStringWithOptions: (NSUInteger)options
{
NSMutableString *string = [NSMutableString string];
NSEnumerator *en = [_children objectEnumerator];
id obj = nil;
[string appendString: @"<?xml version=\"1.0\"?>"];
while((obj = [en nextObject]) != nil)
{
[string appendString: [obj XMLStringWithOptions: options]];
}
return string;
}
@end
@implementation NSXMLDocument (NSXMLParserDelegate)