Click here to Skip to main content
15,498,943 members
Please Sign up or sign in to vote.
3.00/5 (2 votes)
See more:
I came across the following statement made in Micosoft documentation using directive - C# Reference | Microsoft Docs[^] --> "Namespaces come in two categories: user-defined and system-defined. User-defined namespaces are namespaces defined in your code. For a list of the system-defined namespaces, see .NET API Browser."

My question is: Does "system-defined namepace" only refer to namespace `System` and any namespace defined under it? Or is namespace `Microsoft`(and any namespace defined under it) also a system-defined namespace?

I did look in the .NET API browser | Microsoft Docs[^] and yes, namespace Microsoft is in fact in shown in the .Net API browser. However, my confusion is, because "system" is a part of the term "system-defined namespace" my thoughts are that "system-defined namespace" may only be referring to namespace System and any namespace defined under namespace System. But I am unsure. Hence my question concerning namespace Microsoft. Thank in advance.

What I have tried:

.Net API browser, system-defined namespace, Microsoft, C#
Posted
Updated 6-Sep-21 22:11pm
v5
Comments
BillWoodruff 7-Sep-21 6:05am    
Why are you "spinning your wheels" with topics like semantic analysis of NameSpace terminology, when you could be leaning how to program ? There are (surprise !) numerous inconsistencies in MS docs and tutorials, most of which you can safely ignore. The people that write those docs are often technically limited, low-status, employees.
CBennigton 7-Sep-21 13:25pm    
Very true. I have come across my fair share of inconsistencies in docs and tutorials. Thanks for the heads up :)
BillWoodruff 7-Sep-21 19:36pm    
Excellent attitude :) Let me modify my over-broad characterization of tech-writers thus: they CAN be people who have excellent language/grammar skills, good communicators.
Richard MacCutchan 8-Sep-21 12:50pm     CRLF
"The people that write those docs are often technically limited, low-status, employees." I am not sure that is true. In my experience tech writers are on a par with developers. Unless you know something specific about Microsoft.
BillWoodruff 8-Sep-21 21:20pm    
Did you notice I added: "Let me modify my over-broad characterization of tech-writers thus: they CAN be people who have excellent language/grammar skills, good communicators."

1 solution

 
Share this answer
 
Comments
CBennigton 7-Sep-21 3:24am     CRLF
I did in fact look in the .NET API browser and "yes" namespace Microsoft is in fact in shown in the .Net API browser. However, my confusion is, because "system" is a part of the term "system-defined namespace" my thoughts are that "system-defined namespace" may only be referring to namespace System and any namespace defined under namespace System. But I am unsure. Hence my question concerning namespace Microsoft.
Richard MacCutchan 7-Sep-21 3:48am    
All of the namespaces defined in the .NET API are 'system' defined. That is to say they are an integral part of the framework and contain all of the classes that make up the API.
CBennigton 7-Sep-21 4:02am     CRLF
"All of the namespaces defined in the .NET API are 'system' defined." --> So then I take it namespace Microsoft is in fact a "system-defined namespace"?
Richard MacCutchan 7-Sep-21 4:08am    
If it is in the list then it is system defined.
CBennigton 7-Sep-21 4:24am     CRLF
I mean if we are being very specific here then I would say "NO, namespace Microsoft is not in the list" as shown in the lastest version of the .Net framework 4.8 I see sub-namespaces defined under namespace Microsoft such as: Microsoft.Activities.Build, Microsoft.CSharp , etc... which are found in the list, but it does not list just namespace "Microsoft" as part of the list. Thus, I am starting to think that namespace Microsoft is not a system-defined namespace. I would appreciate if you could check that out for me. Concerning namespace System, I do see namespace System and the sub-namespaces defined under namesace System are in the list. So I have no problem there.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900