The Artima Developer Community
Sponsored Link

Java Buzz Forum
Cardinality right in your programming language

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
dion

Posts: 5028
Nickname: dion
Registered: Feb, 2003

Dion Almaer is the Editor-in-Chief for TheServerSide.com, and is an enterprise Java evangelist
Cardinality right in your programming language Posted: Jul 18, 2004 7:27 PM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by dion.
Original Post: Cardinality right in your programming language
Feed Title: techno.blog(Dion)
Feed URL: http://feeds.feedburner.com/dion
Feed Description: blogging about life the universe and everything tech
Latest Java Buzz Posts
Latest Java Buzz Posts by dion
Latest Posts From techno.blog(Dion)

Advertisement
I think I agree with James' thoughts on displaying cardinality in a language (from a comment on Generic type parameter naming A.K.A Line Noise) James Agreed! I do find generics a little jarring on the eye - I'm not convinced of their value in Java other than as introspect-able metadata/reflection. I prefer the X# or Comega approach of using type cardinalities in the language, which solves elegantly most peoples use of generics - type safe collections. class Customer { String! name EmailAddress+ emails PhoneNumber* telNumbers String? comments } which uses DTD-like type modifier postfixes. They're a little wierd at first but they soon feel quite natural, after all we're used to adding [] as a type modifier postfix This is a lot nicer on the eye. With Generics we are seeing different information (a List that contains type X, a Map with keys of Y and values of Z, deciding the implementation of List that you want, etc etc). When whipping together designs (either on a piece of paper, or in a UML tool) we often use this cardinality and do the mental leap to code. Why not use the same form? Going to add this to Groovy, James? :)

Read: Cardinality right in your programming language

Topic: 1.03 - .42 = 0.6100000000000001? No Way! Previous Topic   Next Topic Topic: [Jul 10, 2004 02:43 PDT] 8 Links

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use