日期:2014-05-20  浏览次数:20733 次

namespace中multipart 的问题
今天读书的时候有一句话不太懂,希望大家解答
Note   that   you   are   not   permitted   to   declare   a   multipart   namespace   nested   within   another   namespace
其中multipart   namespace只的是那种格式?能否提供使编译器报错的代码?

这段的全文是:
Each   namespace   name   is   composed   of   the   names   of   the   namespaces   it   resides   within,   separated   with   periods,   starting   with   the   outermost   namespace   and   ending   with   its   own   short   name.   So   the   full   name   for   the   ProCSharp   namespace   is   Wrox.ProCSharp,   and   the   full   name   of   NamespaceExample   class   is   Wrox.ProCSharp.Basics.NamespaceExample.

You   can   use   this   syntax   to   organize   the   namespaces   in   your   namespace   definitions   too,   so   the   previous   code   could   also   be   written   as   follows:

namespace   Wrox.ProCSharp.Basics
{
class   NamespaceExample
{
//   Code   for   the   class   here...
}
}

Note   that   you   are   not   permitted   to   declare   a   multipart   namespace   nested   within   another   namespace



------解决方案--------------------
就是一串字符,中间用点隔开的样子,没什么特别的。
------解决方案--------------------
不像一楼说的
用.隔开而已