Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Patterns, Principles and Practices of Domain-Driven Design
This is the forum to discuss the Wrox book Patterns, Principles and Practices of Domain-Driven Design by Scott Millett; ISBN: 978-1-118-71470-6
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Patterns, Principles and Practices of Domain-Driven Design section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 30th, 2015, 08:59 AM
Authorized User
Points: 136, Level: 2
Points: 136, Level: 2 Points: 136, Level: 2 Points: 136, Level: 2
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2015
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Lightbulb UpperCamelCase Vs under score

I see that on page 312, you use methods with under scores. For example, change_price_to. On page 317 you use UpperCamelCase.

Do you think any special style helps domain design easy? It may look like a stupid question, but think about how this can help new developers or large teams?
Reply With Quote
  #2 (permalink)  
Old May 30th, 2015, 09:43 AM
Wrox Author
Points: 237, Level: 4
Points: 237, Level: 4 Points: 237, Level: 4 Points: 237, Level: 4
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2015
Posts: 59
Thanks: 1
Thanked 5 Times in 5 Posts
Default

In my opinion it's mostly it's based on team and language conventions. When I write scala I use lowerCamelCase. In .NET I use UpperCamelCase and in python I use snake_case to follow community conventions and language style guides.

Mostly in the book we followed the .NET convention of UpperCamelCase, but as you point out we used snake_case in a few places because it does make expressing certain phrases easier to read.

It can make your codebase too inconsistent when you mix different types of casing so it's best to use one or the other consistently in my opinion. But if you think there is a big benefit to using a differing casing in certain places, it's worth considering.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Algorithm to Score Global Quality-Quantity of File asgarcymed VBScript 0 November 24th, 2007 11:12 PM
Display highest test score kgs51 VB.NET 2002/2003 Basics 15 November 19th, 2004 11:02 AM
Coursebuilder Score Script fs22 Javascript 0 April 8th, 2004 09:37 AM
get max test score and corresponding date ssambr1 MySQL 1 January 24th, 2004 08:42 PM
quiz total score frenziedsilence Beginning PHP 2 January 14th, 2004 12:22 AM



All times are GMT -4. The time now is 05:47 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.