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 7855205
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T20:19:00+00:00 2026-06-02T20:19:00+00:00

I have a basic iOS app that interfaces with a Rails app. The idea

  • 0

I have a basic iOS app that interfaces with a Rails app. The idea here is to load all channel objects from my RESTful /channels.json route set up in Rails.

I want to load all of the Channel objects into an NSDictionary in Xcode so that they can easily be identified using the Channel object’s ID generated by ActiveRecord — something along the lines of [dictionary objectForKey:@"1"]

I’ve had no trouble loading all the Channel objects into an NSArray, but getting them to load into an NSDictionary is proving tough. I’ve implemented RestKit’s didLoadObjectDictionary delegate method, and have set up my JSON response as follows: https://gist.github.com/2504664

I believe I have my mapping set up incorrectly. The mapping for the Channel objects is set up as follows: https://gist.github.com/2504667

When the didLoadObjectDictionary method is called, the objects NSDictionary contains 0 key/value pairs.

How do I go about loading all Channel objects into an NSDictionary so that I can easily refer to them using objectForKey as explained above?

  • 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-02T20:19:02+00:00Added an answer on June 2, 2026 at 8:19 pm

    You can still fetch things out of the nsarray using a predicate:

    [someArray filteredArrayUsingPredicate:[NSPredicate predicateWithFormat:@"id = %@", someId]];
    

    It returns another NSArray (which should have one object).

    Alternatively you could use restkit’s coredata mappings then simply fetch the object by ID out of core data.

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

Sidebar

Related Questions

I'm developing an ios app that's very basic and uses objective almost all of
I have an iOS app that needs to publish to a users facebook wall.
I have an iOS app that I want to convert to using ARC .
I have an iPhone (iOS) app that keeps data in a local SQLite database
I have basic idea on Kilo Virtual Machine on Mobiles , I have clear
I have a basic form with controls that are databound to an object implementing
I have a basic understanding of mock and fake objects, but I'm not sure
I have a basic CRUD form that uses PageMethods to update the user details,
I've reviewed many websites and youtube videos that have IOS 5 storyboarding information. Most
Here's the error: In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/ios:39, from /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/ostream:40, from /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/iostream:40, from date.h:15,

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.