Join Reynald Adolphe for an in-depth discussion in this video Namespaces, part of C# Best Practices for Developers.
- [Instructor] An important part of classes are namespaces.…You might have noticed that when you created a project…Visual Studio created a namespace around our class.…So for example, on the right here, in our solution…explorer our project name was prestige.biz.…And as you can see on line seven that is exactly…what the namespace is called.…Namespaces provide a unique address for our class…and organize the application classes in a logical hierarchy.…
And those hierarchies can be somewhat complex…and an example is the .net system a namespace.…Let's take a look at lines one through five.…This hierarchy, by grouping functionality, helps us…be able to find what we are looking for easily.…So if I were to comment out line one…I no longer will have access to our console,…but I can type in system…to be able to get access to it.…
So it's a good practice though to avoid this…and use namespaces…just like we do on line one to minimize redundancy.…And when you're not using classes that are in some…default namespaces it's a good idea to just clean it up.…
- Naming and handling classes
- Running a unit test
- Using constructors
- Naming and handling methods, fields, and properties
- Using properties correctly
- Managing objects efficiently
- Common design patterns as best practices
Skill Level Intermediate
1. Best Practices: An Overview
2. Naming and Handling Classes
3. Naming and Handling Methods, Fields, and Properties
4. Managing Objects Efficiently
5. More Best Practices Resources
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.