• 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: Design Best Practice Question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Design Best Practice Question


  • Subject: Re: Design Best Practice Question
  • From: James Cicenia <email@hidden>
  • Date: Tue, 22 Mar 2005 14:16:24 -0600

Pierre -

That concept worked great for me, with some obvious tweaks that relate to my exact model. NOW, is there any other
very simple concept of writing back values, i.e. either editing or instantiating new metricTypeValue objects?


Thanks again,
James Cicenia

On Mar 22, 2005, at 10:23 AM, <email@hidden> wrote:

James,

I would cache the type to value mapping in a dictionary held as instance variable of Project.

this.valuesForTypes = new NSDictionary(meytricTypeValues(), (NSArray) metricTypeValues().valueForKey(MetricTypeValues.METRIC_TYPE));

Display code may loop over a Portfolio's type list and query the Project's dictionary:

	project.valueForTypes().objectForKey(type)

Pierre Bernard
http://homepage.mac.com/I_love_my

-----Original Message-----
From: webobjects-dev-bounces+pierre.bernard=email@hidden
[mailto:webobjects-dev-bounces+pierre.bernard=email@hidden]On
Behalf Of James Cicenia
Sent: Tuesday, March 22, 2005 3:46 PM
To: WOdev List
Subject: Design Best Practice Question


Hello -

I have the following scenario.

Portfolio -->> MetricTypes

Project -->> MetricTypeValues  --> MetricType

However, a project doesn't have to have a value for each metric type,
however, it needs to display the list of metric types.

What is the appropriate best practice to handle this type of
relationship?

Do I create an array in project from the Portfolio's Metric Types and
then see if it has a MetricTypeValue?

Thanks,
James Cicenia

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


This email sent to email@hidden




********************************************************************** This email and any files transmitted with it are intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the sender of this message. (email@hidden) This email message has been checked for the presence of computer viruses; however this protection does not ensure this message is virus free. Banque centrale du Luxembourg; Tel ++352-4774-1; http://www.bcl.lu **********************************************************************


_______________________________________________ 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: 
 >RE: Design Best Practice Question (From: <email@hidden>)

  • Prev by Date: Re: ANY DB2 Experts Here????
  • Next by Date: How to do a "SELECT DISTINCT"
  • Previous by thread: RE: Design Best Practice Question
  • Next by thread: Linking Array elements to WOComponents
  • Index(es):
    • Date
    • Thread