Home > Articles > Programming > Java

Java Perspective: Advanced Core Data

Marcus Zarra
  • PrintPrint
  • Share ThisShare This
  • DiscussDiscuss
Close WindowMarcus Zarra

Marcus Zarra

Learn more…

Basic Animations with Core Animation
Dec 28, 2009
Marcus Zarra and Matt Long on Core Animation
Jun 5, 2009
Introduction to Migration in Apple's Core Data
Mar 7, 2008
A Look at Apple's Core Animation
Feb 1, 2008
The State of Java Development on OS X
Jan 4, 2008
Packaging Your Application for OS X
Nov 21, 2007
Tiger vs. Leopard: Which Should You Develop For?
Oct 26, 2007
Building on Apple Sync Services
Sep 8, 2006
Getting in Sync with OS X
Sep 1, 2006
Syncing Your Data the Cocoa Way
Aug 11, 2006
Controlling Both Ends of the Communications Channel: From Cocoa to Servlets
Jun 2, 2006
Cocoa: Working with XML
May 19, 2006
Java EJB 3.0: A Hibernate Clone?
Apr 28, 2006
Document Level Parameters Using Core Data: A Guide for Cocoa Developers
Apr 7, 2006
Tips for J2EE Development
Feb 24, 2006
The Cross-Platform Java GUI: Designing Code for More Than One Operating System
Feb 10, 2006
Avoiding Java Exception Abuse
Dec 22, 2005
Java Perspective: Advanced Core Data
Dec 16, 2005
Java Perspective: Cocoa-Java Bridge
Dec 1, 2005
Java Perspective: Core Data and the Mac OS X Developer
Nov 23, 2005
Java Perspective: Key-Value Protocols, Behind the Magic of Mac OS X Development
Nov 11, 2005
Java Perspective: Cocoa Subclasses and Delegates
Nov 4, 2005
The Java Perspective: Cocoa's Interface Builder
Oct 21, 2005
Maven: Handling Multiprojects
Sep 23, 2005
Java, Maven, and Your Web Development Project
Aug 26, 2005
Ant User, Let Me Introduce Maven
Jul 29, 2005
Using JAAS Authentication with JBoss
Jun 17, 2005
Building a Custom JBoss Login Module
Jun 10, 2005
Testing Java Enterprise Applications with Cactus
May 20, 2005
Ant: Building a Better Build File
May 6, 2005
XDoclet: Entity Bean Relationships
Apr 8, 2005
The Java Developers' Introduction to XDoclet
Jan 7, 2005
An Introduction to Cactus
Dec 30, 2004
Using Multiple Databases with JBoss
Nov 24, 2004
JBoss Application Configuration Breakdown
Nov 5, 2004
Sortable Swing JTable
Oct 1, 2004
Building a Professional Swing JTable
Sep 10, 2004
Creating a Custom Java Swing Tablemodel
Aug 27, 2004
Adding Workflow Control to Your Java Applications
Mar 26, 2004
The Mac Developer Network
By on November 21, 2007 No Comments
Steve Scott of Late Night Cocoa has started a new podcast targeted specifically at Macintosh Developers.  One of the first episodes on this podcast is a roundtable of developers with several very well known developers starting with Daniel Jalkut, Uli Kusterer and Fraser Spiers along with myself.
Once more unto the [Beta Cycle], dear friends, once more
By on November 16, 2007 No Comments
Today marks the first semi-public release of iWeb Buddy, a new application that I have been developing for the past few months.  Unlike seSales or applications developed as a consultant, this development cycle has been a blur of activity.
Apple -- You Did Me A Disservice
By on October 26, 20073 Comments
Today is the day that most Mac users have been looking forward to for over a year.  Ever since Steve Jobs got up on stage last August and showed us Leopard for the first time.  Ever since that first peak almost all Mac users and I dare say ALL Mac developers have been looking forward to this release.  Unfortunately, today is also a day that Mac developers are going to be scrambling like rats on a burning ship.  This is because Apple decide to thumb their nose at us.
Further development of Bullfrog 2 for OS X
By on October 11, 2007 No Comments
Things are starting to speed up on the development of Bullfrog 2 previously mentioned here.  In our continuing disclosure about the development process, Jon Trainer has written a very informative article on how the actors are configured.
Starting over is hard to do
By on September 18, 2007 No Comments
I mentioned before that I am working with Jon Trainer of Outer Level to write Bullfrog 2 for OS X.  This development effort will be targeted at the as of yet unreleased OS X 10.5 Leopard.  We also promised to blog about the development as it moved forward.  Unfortunately not everything has been roses.
Although it is possible to use Core Data with little or no coding on your part, what if you want or need more fine-grained control over the persistence layer in your application? In this third article in his Core Data series from a Java perspective, Marcus Zarra walks you through some of the more advanced features of Core Data. Specifically, you'll learn how to retrieve data from a Core Data repository without having to write full SQL queries and how to access the data in Core Data entities.
Java

For more information on Java development, visit our Java Reference Guide or sign up for our Java Newsletter.

Although it is possible to utilize Core Data with little or no coding on the part of the developer, what if you want or need more fine-grained control over the persistence layer in your application? This article walks you through the process of accessing a Core Data persistent store directly in code.

NSManagedObjectModel

The NSManagedObjectModel represents the model that the developer designs using XCode. It contains all the entities for the application, including all the attributes for those entities and the relationships. A Core Data application has at least one model and can contain as many as is necessary. The NSManagedObjectModel is similar in use to a database schema.

The model is not normally accessed directly by the developer other than to pass a pointer/reference to it to other objects such as the NSManagedObjectContext detailed below.

  • Share ThisShare This
  • Your Account

Discussions

Make a New Comment

You must log in in order to post a comment.

Related Resources

Jennifer  BortelWin FREE iPhone Developer Books and Videos- Introducing @InformIT Giveaways
By Jennifer Bortel on February 5, 2010 No Comments

Apples’s recent iPad announcement made our hearts flutter so we couldn’t resist making an announcement of our own!

Today marks the first ever @InformIT Giveaway!

We’ll regularly post a video like this one profiling spectacular prizes we’re giving away—from books and videos to T-shirts and other exciting stuff. Check out the video below to see the giveaways for today, and then scroll down for more prize details and instructions on how to win them!

So Far So Good
By John Traenkenschuh on February 2, 2010 No Comments

So far, Win 7 is making a thoroughbred of what has been a plough mule laptop

Dustin Sullivan"Every OSX developer should have this book on their desk."
By Dustin Sullivan on February 1, 2010 No Comments

That was the sentence Mike Riley ended his recent Dr Dobb's CodeTalk review of Cocoa Programming Developer's Handbook with.

See All Related Blogs

Informit Network