Re: modeling NSManagedObject with large binary data attribute
Re: modeling NSManagedObject with large binary data attribute
- Subject: Re: modeling NSManagedObject with large binary data attribute
- From: mmalcolm crawford <email@hidden>
- Date: Mon, 24 Oct 2005 08:56:22 -0700
On Oct 24, 2005, at 5:56 AM, Jesse Grosjean wrote:
But I've just tried the simpler path and am now using a standard
"Binary Data" attribute in my entity instead of a relationship to
manage this data. And it seems like this is method works too. For
instance if I attach a large NSData (~150 mb) it appears (when I
print the object in the console) that this data is loaded as soon
as my managed object is loaded. But my applications launch time and
memory usage suggest this isn't really true. I'm guessing that the
NSData is being smart and lazily loading the data as needed.
First, "lazy loading" only applies with the SQLite store -- with the
XML and binary stores the whole data set is loaded into memory at once.
Second, all a managed objects attributes are loaded at the same
time. If you have an object with a 150MB attribute, that attribute
will be loaded at the same time the object is fetched.
Are you sure that the object in question is being fetched when your
application launches? (That it itself is not a fault.)
mmalc
_______________________________________________
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