From collectibles to cars, buy and sell all kinds of items on eBay
home | pay | site map
Shop for itemsSell your itemTrack your eBay activitiesLearn, connect, and stay informed-for business and for funGet help, find answers and contact Customer SupportAdvanced Search
Home > Listing Index > Games > Core Data

Games - Core Data


Overview

Core Data is part of the Cocoa
API in Mac OS X
, first introduced in Mac OS X 10.4 Tiger
. It allows any sort of data organized by the relational entity-attribute model, to be serialized into XML, binary, or SQLite stores. The data can be manipulated using a higher level set of objects representing entities and their relationships. Core Data manages the serialized version, providing object lifecycle and object graph management, including persistence. Core Data interfaces directly with SQLite, insulating the developer from the underlying SQL.

Just as Cocoa Bindings handles many of the duties of the controller in a Model-View-Controller design, Core Data handles many of the duties of the model. Among other tasks, it handles change management, serializing to disk, memory footprint minimization, and queries against the data.

Usage

In use, Core Data allows the developer to describe their data with a high level data model expressed in terms of entities and their relationships, plus fetch requests that retrieve entities meeting specific criteria. Code can retrieve and manipulate this data on a purely object level, without having to worry about the details of storage and retrieval. Further, the controller objects available in Interface Builder
(IB), the standard GUI building tool for Cocoa, can retrieve and manipulate these entities directly. When combined with Cocoa bindings, the UI can display many components of the data model without needing background code.

For instance, a developer might be writing a program to handle vCards. In order to manage these, the author intends to read the vCards into objects, and then store them in a single larger XML file. Using Core Data the developer would drag their schema from the data designer in Xcode into an IB window to create a GUI for their schema. They could then write standard Objective-C code to read vCard files and put the data into Core Data managed entities. From that point on the author's code manipulates these Core Data objects, rather than the underlying vCards. Connecting the Save menu item to the appropriate method in the controller object will direct the controller to examine the object stack, determine which objects are dirty, and then re-write a Core Data document file with these changes.

Storage Formats

Core Data can serialize objects into XML, Binary, or SQLite for storage The details of how these are stored vary between formats - the XML store tries to make a file readable by other programs, while the SQLite store generates rather opaque files. This portion of Core Data is similar to the original EOF system, in that one can write fairly sophisticated queries. Unlike EOF, it is not possible to write your own SQL, likely because this would not be supported by the XML and Binary storage types.

Core Data schemas are standardized. If you have the Xcode Data Model file, you can read and write files in that format freely. Unlike EOF, though, Core Data is not currently architected for multiuser or simultaneous access. Schema migration is also non-trivial, virtually always requiring code. If other developers have access to and depend upon your data model, you may need to provide version translation code in addition to a new data model if your schema changes.

History and Genesis

Core Data owes much of its design to an early NeXT product, Enterprise Objects Framework (EOF).

EOF was specifically aimed at object-relational mapping for high-end SQL database engines such as SQL Server and Oracle. EOF's purpose was twofold, one to connect to the database engine and hide the implementation details, and two to read the data out of the simple relational format and translate that into a set of objects. Developers typically interacted with the objects only, dramatically simplifying development of complex programs for the cost of some "setup". The EOF object model was deliberately set up to make the resulting programs "document like", in that the user could edit the data locally in memory, and then write out all changes with a single Save command.

Throughout its history EOF "contained" a number of bits of extremely useful code that was not otherwise available under NeXTSTEP/OpenStep
. For instance, EOF required the ability to track which objects were "dirty" so the system could later write them out, and this was presented to the developer not only as a document-like system, but also in the form of an unlimited Undo command stack. Many developers complained that this state management code was far too useful to be isolated in EOF, and it was moved into the Cocoa API
during the transition to Mac OS X
.

[ Visit the complete Wikipedia entry for Core Data ]


Searches on eBay

Some related entries: MacX | Bristol Zoo | Arachnos | Las Plagas | Elizabeth McCoy | Sectoid | Sega Visions | Nintendo Vs. Series | Catch Phrase | Kagome Kagome | LucasArts adventure games

eBay Pulse | eBay Reviews | eBay Stores | Half.com | Kijiji | PayPal | Popular Searches | ProStores | Rent.com | Shopping.com
Australia | Austria | Belgium | China | France | Germany | India | Italy | Spain | United Kingdom

About eBay | Announcements | Security Center | Policies | Site Map | Help