namespaces + types

  • Thread starter Thread starter wh
  • Start date Start date
W

wh

When I see a reference to a type, in most cases a comma seperates the type
itself and what appears to be the name of an assembly, e.g.

type="System.Web.UI.PageHandlerFactory, System.Web"

My question is whether System.Web in the above example is the name of an
assembly that the PageHandlerFactory resides in (in this case
System.Web.Dll). If so, what is the purpose behind this? Extra security?

Thanks,
Wayne.
 
Wayne,
The second System.Web is the name of the assembly.

Remember that a namespace can be spread across multiple assemblies, by
listing the assembly with the fully qualified type name, you are certain to
find the type in the correct assembly.

For example: the System.Uri class is in the System assembly (System.dll)
while the System.String class is in the mscorlib assembly (mscorlib.dll).

For details on fully qualified type name see:

http://msdn.microsoft.com/library/d...ml/cpconSpecifyingFullyQualifiedTypeNames.asp

Hope this helps
Jay
 
Back
Top