Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Jul 1, 2011, 10:39 AM   #1
tamvly
macrumors 6502a
 
tamvly's Avatar
 
Join Date: Nov 2007
Quick questions from developer new to Mac OS

Hoping for a little help here ...

For those of you who have already done the work of learning the Mac OS frameworks and APIs I am hoping for confirmation that a few of the following have robust implementations in the MAC OS X APIs:

in memory data-base accessible though SQL
backing store for data to be loaded into said in-memory database
full compliment of XML APIs

Thanks in advance.
tamvly is offline   0 Reply With Quote
Old Jul 1, 2011, 12:10 PM   #2
chown33
macrumors 603
 
Join Date: Aug 2009
Quote:
Originally Posted by tamvly View Post
Hoping for a little help here ...
What have you tried?

Have you searched extensively and found nothing?
Searched extensively and found conflicting information?
Not searched at all?

If it's either of the first two, then please explain what search terms you tried and what the results were. If there are conflicts in what you found, describe them.

If you haven't searched at all, then you should at least try the obvious search terms:
mac os x sql
mac os x sql in-memory
mac os x xml api
mac os x xml class
mac os x xml library
chown33 is online now   0 Reply With Quote
Old Jul 1, 2011, 03:55 PM   #3
tamvly
Thread Starter
macrumors 6502a
 
tamvly's Avatar
 
Join Date: Nov 2007
I should have mentioned in my op that I have tried searches such as those suggested by chown, with little success.

Any suggestions would be appreciated.
tamvly is offline   0 Reply With Quote
Old Jul 1, 2011, 04:48 PM   #4
Catfish_Man
macrumors 68030
 
Catfish_Man's Avatar
 
Join Date: Sep 2001
Location: Portland, OR
Send a message via AIM to Catfish_Man
Quote:
Originally Posted by tamvly View Post
I should have mentioned in my op that I have tried searches such as those suggested by chown, with little success.

Any suggestions would be appreciated.
sqlite and Core Data come to mind as possibilities for the first two. Cocoa has NSXMLParser (SAX), and NSXMLDocument (DOM) for XML, and the lower level libxml2 api is also available.
Catfish_Man is offline   0 Reply With Quote
Old Jul 1, 2011, 04:58 PM   #5
chown33
macrumors 603
 
Join Date: Aug 2009
Quote:
Originally Posted by tamvly View Post
I should have mentioned in my op that I have tried searches such as those suggested by chown, with little success.
Please explain in more detail.

Exactly what search terms did you use? Which search engine?

Exactly what were you unsuccessful in finding? Information about SQL databases in general? About in-memory ones? About their robustness?

What was unsuccessful about searches for XML APIs? Information about library or class features? About compliance with standards? About reliability or robustness?


I did not post that list of search terms randomly. I don't usually do this, but I'm going to summarize the search results, and give a cursory analysis of what seem to be the most promising results from the first page of results.

First, I only used google. I entered the search terms into the google home page search field, not into the search field in my browser window. I mention this in case another search engine might give other results, or a browser sends different supplemental query data.

I'm located in the USA, so if google returns locale-specific results, please take that into consideration.

If I mention the position of a specific result, yet you see something different (such as no such result at all), then maybe something is different about how your google search is being qualified by your browser.


Terms: mac os x sql

Results:
Top hit: a MySQL article discussing how to install MySQL on Mac OS X, and mentioning when it's already present by default (i.e. Mac OS X Server).

The remainder of hits on the first page seem more like product placement, but there is certainly a range of products. When I encounter situations like this, the first thing I do is narrow the search to the specific site of a promising result. Site-specific search is something every developer should know how to do.

Narrowed terms: mac os x sql site:developer.apple.com

Results:
Second hit is about PostgreSQL. Then several items from the "Mac OS X Manual Pages" section of the site.

Seventh hit, and the next one that looks different from the man pages, is for Core Data Programming Guide: Persistent Store Features.

If unfamiliar with what Core Data is, could perform a secondary search about that, but can come back to that. Clicking the link shows a table with headings for XML, Atomic, SQLite, and In-Memory. SQLite is a product name worth remembering for additional searches. In-memory looks promising for further research. I'll let you read the actual page for further details.


Terms: mac os x sql in-memory

Results:
Top hit: the above Core Data Programming Guide: Persistent Store Features article. Hmm, really should do some research into this. Might be useful, or it might not, if only we knew more details about the requirements.

Not much else seems relevant on the first page of hits.

At this point, I begin to wonder exactly what the in-memory requirement is for. Is it for speed? Speed of what: Queries? Updates? What size is expected? What precautions will there be to prevent thrashing due to VM paging? An in-memory database may cause memory pressures that result in paging, which degrades overall performance, where a database that used backing-store on disk may not suffer that kind of paging, or perhaps not to the same degree. Thinking about backing-store makes me wonder what the database's intended use is. There's a wide range of potential uses, and it's entirely possible that a fast SQLite database more than meets the actual requirements. If only we knew more about what those requirements were.


Terms: mac os x xml api

Results: Meh. Too generic.
- Cocoa API defined by wikipedia
- Property list defined by wikipedia
- Google queries
- Lua
- Python bindings
etc.

Strategy: try a different word for one of the search terms. Taking a clue from what Cocoa is (an object-oriented framework), I choose the word class to replace api, on the hypothesis that if there are any Cocoa classes for XML, this is likely to produce results.


Terms: mac os x xml class

Results:
Top hit: NSXMLParser class reference doc. Click the link to read what it does. So: event-driven parser, supports DTDs, etc. etc.

The class looks promising, especially after investing a little time to read the Companion Guide linked to, and then the Related Documents noted in the Event-Driven XML Programming Guide.

Next, replacing class with library in search terms...


Terms: mac os x xml library

Results:
Multiple XML parser libraries that say they work on Mac OS X. The top hit is for libxml2, which bears further searches regarding its reliability, robustness, and which version is shipped with which OS version. The MIT license will make it easy to embed in an app, if necessary to achieve reliability requirements. Which makes me wonder exactly what the robustness and reliability requirements actually are.


So, this is what I tried. The results look like much more than what could be called "little success", but without knowing exactly what you're looking for, I'm not really sure. Asking about generic terms like SQL, XML, and "robust" doesn't give enough detail to answer. Especially if you aren't asking about specific classes, libraries, or sets of requirements with a stated purpose.

I don't expect you to post your entire search strategy, with annotated results, like I did above. I wrote all that only to show what the actual results were, and to show how easily those results were found from the exact search terms I first provided. If specifics like MySQL, SQLite, NSXMLParser, and libxml2 are what you consider "little success", then I suggest that you haven't clearly explained what problem you're trying solve, nor what kind of answer you're expecting us to provide. Conversely, if you have a specific question about one of those specific items, then you should ask a specific question about a specific thing.

Last edited by chown33; Jul 1, 2011 at 05:24 PM.
chown33 is online now   0 Reply With Quote
Old Jul 1, 2011, 05:51 PM   #6
tamvly
Thread Starter
macrumors 6502a
 
tamvly's Avatar
 
Join Date: Nov 2007
Thanks for the list. I really appreciate it.

I believe the mistake I made was using only MacRumors as a source of searches. I sorted through literally hundreds of posts that we're completely irrelevant.

Now where my brain was in all of this when I should have used a search engine other than MacRumors to begin with, I don't know. POint made.
tamvly is offline   0 Reply With Quote
Old Jul 1, 2011, 06:50 PM   #7
chown33
macrumors 603
 
Join Date: Aug 2009
Quote:
Originally Posted by tamvly View Post
I believe the mistake I made was using only MacRumors as a source of searches. I sorted through literally hundreds of posts that we're completely irrelevant.
This is exactly the kind of reply I was expecting when I asked "What have you tried?".

If you had posted this in reply I would have said "MacRumors is not a search engine; it's a website with search. Try google or bing instead."

Quote:
Now where my brain was in all of this when I should have used a search engine other than MacRumors to begin with, I don't know. POint made.
In the future, when someone asks "What have you tried?", I hope you will succinctly describe what you actually tried, instead of simply saying you obtained little success, yet never describing what you did.
chown33 is online now   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
Couple questions regarding iOS 7 Beta 2 [too late to buy developer account?] gcooldude iOS 7 5 Jun 25, 2013 10:12 PM
Developer questions zgmg Mac Programming 2 Apr 14, 2013 09:45 AM
questions to "Apple Developer Programs" for iOS (and Mac) as Non-Programmer Quotenfrau iOS 6 7 Aug 18, 2012 10:30 AM
Some quick questions: Raid 5 controller & setup in 2008 or 2009 Mac Pro mbgt72 Mac Pro 2 Aug 9, 2012 12:36 PM
Apple Developer Program Questions bherzberg96 iPhone/iPad Programming 15 Jun 12, 2012 02:39 AM

Forum Jump

All times are GMT -5. The time now is 02:21 PM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013, MacRumors.com, LLC