Adding core data to my iPhone app - iphone

I have been here before, asking for a mapping library that could store objects in a database. Some one told me about the Core Data Framework. I have read a bit about it and I kindda understand it.
I have created some "test Core data projects", where I have worked with simple problems and models ala Person and Group. But now I want to experiment with implementing Core Data to one of my small iPhone apps. How do I do this? Subclassing from NSManagedObject and make a Managed Object Model?
I know that there is more to it, but I havent found anything on google og apples site. Maybe Im looking in wrong direction while googling and searching.
A link to an article/tutorial explaining me how to add Core Data to my project would make my day.

There's a tutorial on iPhone developer site here. And there are several sample codes with Core Data as well. These should get you started.

The book, More iPhone 3 Development begins with a great tutorial demonstrating how to use Core Data. I've found it incredibly helpful.

Here is a basic CoreData screencast that, while not specifically for the iPhone gives a decent introduction to CoreData concepts.

Related

How can I add data to a coreML file within an app

I want to create a handwriting recognition app (probably using a CoreML framework but open to other suggestions). I know how to create a framework and teach it using the playground interface, but I'm wondering if I can train the framework within an app so I would ask the user to write specific words which would teach the program according to that user's handwriting.
I've looked into other OCR software such as Tesseract and SwiftyOCR, I have also tried using an existing coreML framework but they are either outdated or very inaccurate, especially considering users will have different handwriting.
Don't know if this is useful 😂but I'm supposed to show some code, so this is the code to create the framework...
import CreateMLUI
let builder = MLImageClassifierBuilder()
builder.showInLiveView()
In the end, I hope to develop an application with a drawing interface (using a UIView) which will prompt the user to write the words or letters that appear on the screen. Later, the software should then be able to recognise their handwriting.
Thanks,
Jordan.
Take a look at this WWDC Session Video.
Sounds like, this is exactly your use case.
https://developer.apple.com/videos/play/wwdc2019/704/

How to have mp3 files in some sort of database and access in ios?

I'm new to iOS, and I'm trying to write an app that uses mp3 files. In fact, this app will have a lot of mp3 files, and in order to avoid a huge app that takes a ton of space and forever to download, I wanted to put it into some sort of database or file server, and when the user clicks on the name of song, the app accesses the database and loads the file. How do I do this? Is it with an SQLite database?
Thanks,
Gagan
I'd make sure you become intimately familiar with CoreData, Apple's persistence framework. I'd stay away from doing raw SQLite access, just because CoreData will do all of the heavy lifting for you. Just as a pointer, I wouldn't store the MP3 files themselves in CoreData, but rather store the file system references to them.
If the Apple documentation is a little dry for you, Pro Core Data from Apress is an excellent primer for learning the basics of CoreData, as well as progressively going deeper into the intricacies of the framework.
You have to create NSData and insert that into the the model. There is a another post with a snippet of code that could be useful to you here: Download, save, and play mp3 on an iPhone
CoreData can be intimidating if you have not experienced it yet, but in reality it is a very easy to use. If you are not familiar with CoreData I would suggest checking out the Docs from Apple and spend a few hours googling and crating "test" apps to learn how to create, insert and delete managed objects. Here is Apples Docs:
http://developer.apple.com/library/mac/#documentation/cocoa/Conceptual/CoreData/cdProgrammingGuide.html
Hope this helps

iPhone: Building talking puppet application

I am trying to learn and build talking puppet iPhone application. The great example is "Talking Ben the Dog" and here is youtube video. I have no idea how am I going to build such application. I have a graphics designer who will do their part. As a being programmer, what would I need to be aware of? If someone can throw their ideas or point me some relavant documentation or sample code would be great help.
Thanks.
First, you'll need to create the content. That means the animation scenes and any associated audio. Next, you'll want to trigger those scenes based upon the user's input.
If you want more advanced functionality like "talk back" where the app repeats what you say, then you'll need to get a grip with AudioQueue and AudioUnit APIs. That means detecting levels of incoming audio then triggering writing audio in to stored buffers. These APIs are difficult so this will be the most technically challenging part. You'll need to be comfortable with pointers and other lower level programming concepts.
For an app without talk back, a lot of work will be required to create the content. Then you'll need to re-create the animations using UIImage and the Core Animation framework in your app.
There are a lot of great videos on the Apple site and sample code. This will be a brilliant learning curve for you to get up to speed with Core Animation.
Just make a couple of videos for every scene and play them according to button click!

How to retrieve data from a website into an iphone app

I am making an iphone application.
I am a newb.
I want to fetch the data from my website. What should i do to implement this?
What needs to be done?
Help me please
Thanks
Any tutorials would be of great help.
If your problem is getting data from website to iphone then you can just use JSON Parsing to get data.
Just you have to pass all the data as JSON string in iPhone from your website. And then parse the data once received into your iPhone.
Here you can refer to this link
http://www.raywenderlich.com/5492/working-with-json-in-ios-5
Hope this helps you
You will be using the NSURLConnection, NSURLRequest and NSURL classes here is an example from Apple; http://developer.apple.com/library/mac/ipad/#documentation/Cocoa/Conceptual/URLLoadingSystem/Tasks/UsingNSURLConnection.html
Expose your data from your site as WebService, XML, JSON etc. Consume that using iPhone app.
Which language is being used your site?depending on that some sample could be provided.
Chapter 10 of James Kennard, Mastering Joomla! 1.5 : APIs and Webservices contains 8 pages about XML-RPC.
For real-live examples, search the Joomla! Extension Directory.
http://extensions.joomla.org/extensions/search/xml-rpc
Here is another one to kick-start http://www.slideshare.net/coolparth/rest-api-for-joomla
For the server side, I suggest using a web service to send the data to your client.
ORIGINAL AUTHOR'S REVISION:
The September issue of Linux Journal has an excellent article on writing mobile apps that work for Android AND iPhone/iPad using free tools and frameworks. Here is a link to the article online:
Developing Portable Mobile Web Applications
Previous answers suggest using NSURLConnection, but I find it to be a bit cumbersome to use on its own. I suggest using something that wraps NSURLConnection (or CFNetwork). Some examples: ASIHTTPRequest (CFNetwork-based), httpriot and Seriously (NSURLConnection/block-based).

Help developing a very simple iPad application

I need to develop a very simple iPad application that takes RSS feed of images that will be updated constantly and will display them and you can slide through them. As simple as that.
Is there a way to get basic help on doing this, I am very new to iPhone/iPad development and would like help.
To make the question clearer, I would appreciate code samples (other than the ones displayed on Apple's developers site, tutorials, and guidelines.
Thank you :)
First things first, you need to go through some Cocoa Touch tutorials and learn how all the pieces fit together. ;-)
Then check out some NSURLConnection samples on how to pull data down from the network.