• 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: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)


  • Subject: Re: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
  • From: Ramsey Gurley <email@hidden>
  • Date: Sat, 03 Mar 2012 10:51:08 -0700


On Mar 3, 2012, at 10:21 AM, Amy Worrall wrote:

A D2WContext stores some state, such as the current entity, the
current property key, etc… who sets them?


The values are are either pushed into the context like a normal dictionary or determined by Assignments when a rule is fired.


Does the D2WComponent that's
currently being rendered set those things on the D2WContext first,
before querying things that the context might have to evaluate rules
for?


The components usually ask the context for the values and they are resolved by the rule system. Occasionally components will push a value.


Is there just one D2WContext that is passed around, with its
properties reset for each component it comes across, or is there a
brand new one created every time a component is displayed?


Within a page, a single context is passed around. Some property level components will create a copy when needed.  Each nested D2WPage gets its own context.


I know
there's an initialiser that takes a parentContext attribute, so that
suggests that a new one is created for each component but initialised
by default to the values of the D2WContext for the containing
component… is that right?


Sometimes, but mostly it's initialized clean and then keys are pushed like pageConfiguration.


Leaving aside the issue of cacheing, are there a set of keys that the
D2WContext stores as state, and everything else is in the rules system
and can be recomputed on the fly if necessary?


Anything resolved can be re-resolved.  Anything pushed needs to be pushed again.

Ramsey

 _______________________________________________
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

  • Follow-Ups:
    • Re: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
      • From: Amy Worrall <email@hidden>
References: 
 >Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT) (From: Amy Worrall <email@hidden>)

  • Prev by Date: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
  • Next by Date: Re: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
  • Previous by thread: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
  • Next by thread: Re: Direct To Cocoa App, or How Does D2WContext Work Anyway? (Somewhat OT)
  • Index(es):
    • Date
    • Thread