@@ -18,13 +18,13 @@ #include #import "OFLocale.h" #import "OFArray.h" #import "OFDictionary.h" +#import "OFIRI.h" #import "OFNumber.h" #import "OFString.h" -#import "OFURI.h" #import "OFInitializationFailedException.h" #import "OFInvalidArgumentException.h" #import "OFInvalidFormatException.h" #import "OFOpenItemFailedException.h" @@ -360,13 +360,13 @@ + (OFString *)decimalSeparator { return currentLocale.decimalSeparator; } -+ (void)addLocalizationDirectoryURI: (OFURI *)URI ++ (void)addLocalizationDirectoryIRI: (OFIRI *)IRI { - [currentLocale addLocalizationDirectoryURI: URI]; + [currentLocale addLocalizationDirectoryIRI: IRI]; } - (instancetype)init { self = [super init]; @@ -491,25 +491,25 @@ [_localizedStrings release]; [super dealloc]; } -- (void)addLocalizationDirectoryURI: (OFURI *)URI +- (void)addLocalizationDirectoryIRI: (OFIRI *)IRI { void *pool; - OFURI *mapURI, *localizationURI; + OFIRI *mapIRI, *localizationIRI; OFString *languageCode, *countryCode, *localizationFile; OFDictionary *map; if (_languageCode == nil) return; pool = objc_autoreleasePoolPush(); - mapURI = [URI URIByAppendingPathComponent: @"localizations.json"]; + mapIRI = [IRI IRIByAppendingPathComponent: @"localizations.json"]; @try { - map = [[OFString stringWithContentsOfURI: mapURI] + map = [[OFString stringWithContentsOfIRI: mapIRI] objectByParsingJSON]; } @catch (OFOpenItemFailedException *e) { objc_autoreleasePoolPop(pool); return; } @@ -529,15 +529,15 @@ if (localizationFile == nil) { objc_autoreleasePoolPop(pool); return; } - localizationURI = [URI URIByAppendingPathComponent: + localizationIRI = [IRI IRIByAppendingPathComponent: [localizationFile stringByAppendingString: @".json"]]; - [_localizedStrings addObject: [[OFString stringWithContentsOfURI: - localizationURI] objectByParsingJSON]]; + [_localizedStrings addObject: [[OFString stringWithContentsOfIRI: + localizationIRI] objectByParsingJSON]]; objc_autoreleasePoolPop(pool); } - (OFString *)localizedStringForID: (OFConstantString *)ID