You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- (void)parser:(NSXMLParser *)parser didEndElement:(NSString *)elementName namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qName
{
// Update the parent dict with text infoNSMutableDictionary *dictInProgress = [self.dictionaryStack lastObject];
// Set the text propertyif ([self.textInProgress length] > 0)
{
// trim after concatenatingNSString *trimmedString = [self.textInProgress stringByTrimmingCharactersInSet:[NSCharacterSetwhitespaceAndNewlineCharacterSet]];
[dictInProgress setObject:[trimmedString mutableCopy] forKey:kXMLReaderTextNodeKey];
// Reset the text
self.textInProgress = [[NSMutableStringalloc] init];
}
// Pop the current dict
[self.dictionaryStack removeLastObject];
}
When the analysis is completed, item-> text has been nil, I debugged the code, find item-> text after the first, was reset to nil, so I modified the code and commit, please test,thank you
The text was updated successfully, but these errors were encountered:
LeeYZ
added a commit
to LeeYZ/XMLReader
that referenced
this issue
Jan 17, 2016
I have an XML document, in the following format:
Your code:
When the analysis is completed, item-> text has been nil, I debugged the code, find item-> text after the first, was reset to nil, so I modified the code and commit, please test,thank you
The text was updated successfully, but these errors were encountered: