Get RSParser.framework building again.

This commit is contained in:
Brent Simmons 2017-06-25 16:40:29 -07:00
parent e9c19e427a
commit b939d91da0
4 changed files with 1 additions and 65 deletions

View File

@ -38,7 +38,7 @@
#pragma mark - Class Methods
+ (NSArray *)HTMLMetadataWithParserData:(ParserData *)parserData {
+ (NSArray *)htmlLinksWithParserData:(ParserData *)parserData {
RSHTMLLinkParser *parser = [[self alloc] initWithParserData:parserData];
return parser.links;

View File

@ -16,29 +16,6 @@
#import "RSOPMLError.h"
void RSParseOPML(ParserData *parserData, RSParsedOPMLBlock callback) {
NSCParameterAssert(parserData);
NSCParameterAssert(callback);
dispatch_async(dispatch_get_global_queue(QOS_CLASS_DEFAULT, 0), ^{
@autoreleasepool {
RSOPMLParser *parser = [[RSOPMLParser alloc] initWithParserData:parserData];
RSOPMLDocument *document = parser.OPMLDocument;
NSError *error = parser.error;
dispatch_async(dispatch_get_main_queue(), ^{
callback(document, error);
});
}
});
}
@interface RSOPMLParser () <RSSAXParserDelegate>
@property (nonatomic, readwrite) RSOPMLDocument *OPMLDocument;

View File

@ -1,19 +0,0 @@
//
// RSXMLError.h
// RSXML
//
// Created by Brent Simmons on 2/28/16.
// Copyright © 2016 Ranchero Software, LLC. All rights reserved.
//
@import Foundation;
extern NSString *RSXMLErrorDomain;
typedef NS_ENUM(NSInteger, RSXMLErrorCode) {
RSXMLErrorCodeDataIsWrongFormat = 1024
};
NSError *RSOPMLWrongFormatError(NSString *fileName);

View File

@ -1,22 +0,0 @@
//
// RSXMLError.m
// RSXML
//
// Created by Brent Simmons on 2/28/16.
// Copyright © 2016 Ranchero Software, LLC. All rights reserved.
//
#import "RSXMLError.h"
NSString *RSXMLErrorDomain = @"com.ranchero.RSXML";
NSError *RSOPMLWrongFormatError(NSString *fileName) {
NSString *localizedDescriptionFormatString = NSLocalizedString(@"The file %@ cant be parsed because its not an OPML file.", @"OPML wrong format");
NSString *localizedDescription = [NSString stringWithFormat:localizedDescriptionFormatString, fileName];
NSString *localizedFailureString = NSLocalizedString(@"The file is not an OPML file.", @"OPML wrong format");
NSDictionary *userInfo = @{NSLocalizedDescriptionKey: localizedDescription, NSLocalizedFailureReasonErrorKey: localizedFailureString};
return [[NSError alloc] initWithDomain:RSXMLErrorDomain code:RSXMLErrorCodeDataIsWrongFormat userInfo:userInfo];
}