• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Reading Archived Data From File
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Reading Archived Data From File


  • Subject: Re: Reading Archived Data From File
  • From: Nick Zitzmann <email@hidden>
  • Date: Tue, 8 Jun 2004 19:27:16 -0600

On Jun 8, 2004, at 5:02 PM, Frederick C. Lee wrote:

Scenario: My NSMutableDictionary is composed of {CountryName Key/
CountryModel objects}. The CountryModel is a custom class that
contains assorted instance variables including a NSMutableDictionary of
CityModels.

I noticed that you're trying to use NSKeyedArchiver and NSUnarchiver together:

if (![NSKeyedArchiver archiveRootObject:theCountryMDict
toFile:countryDataSource]) { // Good
[...]
theCountryMDict = [[NSUnarchiver
unarchiveObjectWithFile:countryDataSource] retain]; // Fails to
populate theCountryMDict.

I'd suggest trying that again using NSArchiver (not NSKeyedArchiver) to handle the archiving. Or, if you need NSKeyedArchiver, then use NSKeyedUnarchiver to handle the unarchiving.

Nick Zitzmann
<http://www.chronosnet.com/>
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: Reading Archived Data From File
      • From: "Frederick C. Lee" <email@hidden>
References: 
 >Reading Archived Data From File (From: "Frederick C. Lee" <email@hidden>)

  • Prev by Date: Re: Checksums and best way to get'em
  • Next by Date: Re: Checksums and best way to get'em
  • Previous by thread: Re: Reading Archived Data From File
  • Next by thread: Re: Reading Archived Data From File
  • Index(es):
    • Date
    • Thread