Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8321041
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T22:52:51+00:00 2026-06-08T22:52:51+00:00

I’ve seen some of the example of using NSCoder to archive the things in

  • 0

I’ve seen some of the example of using NSCoder to archive the things in your application

@interface MyApplicationData : NSObject <NSCoding, NSCopying> {
    NSMutableArray* items;
    NSMutableArray* categories;
}

Please see this thread. How to use NSCoder

Why does this improve the performance of your app? isn’t that doing more things in your application? Can anyone tell me why and when you want to use archive?

EDITED:
Quoted from a book, iOS 5 programming pushing the limit- Under Method for Storing your Cache: “Caching or saving data can be done either by storing it as archives of your data models (using NSKeyedArchiver) or using a higher-level database like raw SQLite or using object serialization framework like Core Data…” “….NSKeyedArchiver is implemented by implementing the NSCoding protocol.”

I thought NSCoding or NSCoder can be used for Caching and it will improve performance. So is it not good practice to use it for caching?

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T22:52:52+00:00Added an answer on June 8, 2026 at 10:52 pm

    Why does this improve the performance of your app?

    well, you need some context — serialization may or may not “improve performance”. it could improve performance over alternative serialized representations. that may make a difference, or it may not be significant.

    isn’t that doing more things in your application?

    well, if you have a complex structure represented in xml/plist as opposed to a serialized object, then no — the object that knows how to encode/decode itself could be much more performant than xml or json or some other intermediate representation (for a number of reasons). it can also be easier to manage, and represent complex structures more easily (in comparison to intermediate serialization representations).

    Can anyone tell me why and when you want to use archive?

    typically when you want to save an object or object graph’s state to disk, or for transfer to another machine.

    imagine you have document data, and you want to restore that document when the document is reopened — your program must create a representation which correctly reconstructs the object or object graph’s state later on.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I am reading a book about Javascript and jQuery and using one of the
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
We're building an app, our first using Rails 3, and we're having to build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.