O'Reilly logo

From Java to C#: A Developer's Guide by Heng Ngee Mok

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

C.6. Naming namespaces

Like Java package names, C# namespaces should be unique so that the chance of another development team somewhere across the globe choosing an identical name is extremely small.

While Java recommends that you name your Java packages using your company's allocated domain name on the world wide web, Microsoft recommends that you name your C# namespaces like this:

<CompanyName>.<TechnologyName>

For example, a class written by Addison-Wesley's technical department can be placed into the AddisonWesley.TechDept namespace. TechDept can be further divided into multiple namespaces based on the project title.

Additional notes

  • Use plural nouns where appropriate. For example, AddisonWesley. TechDept.SharedUtilities is preferable to ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required