• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Convenience functions in model classes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Convenience functions in model classes


  • Subject: Re: Convenience functions in model classes
  • From: Chuck Hill <email@hidden>
  • Date: Mon, 14 Apr 2008 13:12:16 -0700


On Apr 14, 2008, at 1:02 PM, Ray Kiddy wrote:


On Apr 14, 2008, at 11:30 AM, Chuck Hill wrote:


On Apr 11, 2008, at 8:50 PM, Jeff Schmitz wrote:


That seems like an exceedingly odd way to get a single entry on a single Pool. Does the code that calls this not know the Pool? How does it get the Pool and Entry names?


Yes, it will only have the Strings (you gotta start somewhere).

Even if you only have the names,

EOQualifier entryQual = ERXQ.and(Entry.NAME.eq(entryName), ERXQ.equals(ERXQ.keyPath(Entry.POOLKEY, Pool.NAMEKEY), poolName));
Will the fact that entryName is not globally unique (it's only unique within a pool) have any affect on the speed of the fetch? There will be a LOT of entries, and not near as many pools. While I have no idea how the above query will ultimately run, I would think finding the pool first, and then just searching for the entry name from within just that pool would be the most efficient way.

No, that will be slower. You will be doing two fetches, where one would do. Indexes (you will need to add them manually) will keep the queries fast.


If you want to have any concerns about optimization and WO, you really need to get familiar with SQL optimization for relational databases.

<snip>

I missed the first part of this thread (through some lost e-mail). I wanted to check about something though.


As I am looking at this API, I am noticing that the er.extensions package is really, really, really big with lots of different kinds of classes and that there is no package documentation at all.

Would anybody mind if I take a stab at adding javadoc as I try out these classes? Are these classes going to be part of some upcoming factorization?


This organization is legacy. The intention is to organize these into packages for WWDC this year. Or was last time Anjo mentioned it. So I would wait.


Chuck

--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects






_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Convenience functions in model classes (From: Jeff Schmitz <email@hidden>)
 >Re: Convenience functions in model classes (From: Jeff Schmitz <email@hidden>)
 >Re: Convenience functions in model classes (From: Chuck Hill <email@hidden>)
 >Re: Convenience functions in model classes (From: Jeff Schmitz <email@hidden>)
 >Re: Convenience functions in model classes (From: Chuck Hill <email@hidden>)
 >Re: Convenience functions in model classes (From: Ray Kiddy <email@hidden>)

  • Prev by Date: Re: Staying with WebObjects
  • Next by Date: Re: new to ajax
  • Previous by thread: Re: Convenience functions in model classes
  • Next by thread: Re: Convenience functions in model classes
  • Index(es):
    • Date
    • Thread