Re: CoreData questions (data sources and file wrappers)
Re: CoreData questions (data sources and file wrappers)
- Subject: Re: CoreData questions (data sources and file wrappers)
- From: Keith Blount <email@hidden>
- Date: Sat, 22 Apr 2006 14:32:43 -0700 (PDT)
Many thanks for your reply. My confusion really arises
from being completely unfamiliar with Core Data and
having it in my head that it is a completely different
technology (in part because the database-style
terminology throws me), so I am aware that some of my
questions may (do) seem rather silly. The Core Data
docs are (understandably) long and I find them
difficult, which is why I want to be sure I should
head that route before spending more time with them.
I'll try to make myself more clear:
> do you want to
> store the text
> using Core Data? Do you want Core Data to store
> references to
> external text files? Does the text have to be
> readable outside of
> your application?
I do not want Core Data to store the text, merely
references to the files. The text files should be
readable in TextEdit or anywhere else. My file format
is as follows: I have a file wrapper, just a folder
with an extension and an icon, that contains a root
file which is an archive of all of the outline view
data and meta-data. Alongside this file are all of the
text files, which are opened by the application as
appropriate (eg. when a reference to one is clicked on
in the outline view). I use a wrapper rather than have
all of the text stored within one file so that my
users feel safe. They like to see that they can
retrieve their text even if the main file itself
becomes corrupted for any reason.
My main goal in looking at Core Data is to make the
manipulation of the outline data easier; in
particular, gaining Undo/Redo support. I had hoped
that there might be a workaround for the file wrapper
limitation given that my file wrapper is actually
little more than a project folder with an extension,
but if not, this may mean that Core Data is not
suitable for this particular project anyway.
Many thanks again,
Keith
--- mmalcolm crawford <email@hidden> wrote:
>
> On Apr 22, 2006, at 1:12 PM, Keith Blount wrote:
> > 1) Is CoreData useful for Xcode-type applications?
> (My
> > program mainly consists of an outline view and a
> > customised text view used for manipulating and
> > managing large text projects.)
> >
> It's not clear exactly what your goal is. How the
> data is
> manipulated is largely irrelevant. Do you want to
> store the text
> using Core Data? Do you want Core Data to store
> references to
> external text files? Does the text have to be
> readable outside of
> your application?
>
>
> > 2) Does CoreData play well with data source
> methods -
> > that is, is it straightforward to use with views
> in
> > which bindings is not possible?
> >
> Why wouldn't it? (Serious question -- I really want
> to try to
> understand what the confusion is here.)
> [Note in particular:
> <http://developer.apple.com/documentation/Cocoa/
>
Conceptual/CoreData/Articles/cdBasics.html#//apple_ref/doc/uid/
>
> TP40001650-DontLinkElementID_12>.]
>
> > 3) Can I use a file wrapper as my file format when
> > using CoreData? I would like to save the actual
> > CoreData binary file inside a file wrapper along
> with
> > text files generated by and imported into my app
> (I do
> > this now by overriding NSDocument's fileWrapper
> > writing method).
> >
> Not with NSPersistentDocument --
> <http://developer.apple.com/
>
documentation/Cocoa/Reference/ApplicationKit/ObjC_classic/Classes/
>
> NSPersistentDocument_index.html>.
>
>
> > 4) My current model has a number of utility
> methods to help with
> > D'n'D. For instance, I can ask a node whether it
> is a descendant of
> > another node. Could I move all this code over to
> work with a Core
> > Data entity class?
> >
> Again, it's not clear why you would think that you
> could not...
>
> mmalc
>
>
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden