• 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
Saving arbitrary types as property list
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Saving arbitrary types as property list


  • Subject: Saving arbitrary types as property list
  • From: Fraser Speirs <email@hidden>
  • Date: Fri, 8 Mar 2002 08:53:28 +0000

Hi,

Is it possible to implement some protocol on my own objects such that I can perform writeToFile:atomically: on an NSArray of them and have it stored in an xml property list?

The way I do this right now is to implement methods on my custom objects that return a representation of its internal state as an NSArray, and that can recreate the object from an array that was originally written by itself.

Is that the best way to do it? I can't figure out any more direct way of doing it.

Thanks,
Fraser
--
Fraser Speirs
Department of Computing Science - University of Glasgow
Room G161, 17 Lillybank Gardens, Glasgow G12 8QQ

t: 0141 339 8855 ext.0917
e: email@hidden w: www.dcs.gla.ac.uk/~speirsfr
_______________________________________________
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: Saving arbitrary types as property list
      • From: Marcel Weiher <email@hidden>
  • Prev by Date: Re: Complete Cocoa API Reference posted to Apple Developer Site
  • Next by Date: Re: Complete Cocoa API Reference posted to Apple Developer Site
  • Previous by thread: Re: Complete Cocoa API Reference posted to Apple Developer Site
  • Next by thread: Re: Saving arbitrary types as property list
  • Index(es):
    • Date
    • Thread