Should a class have the same name as the namespace?

前端 未结 5 1538
陌清茗
陌清茗 2021-01-19 01:27

I\'m designing a namespace to hold a set of classes that will handle user related tasks for a several different applications. (Log-in, authenticate etc)

5条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-19 01:40

    I'd probably call the name space 'usertasks' to avoid any confusion. You are going to have to qualify the inner class using the namespace regularily to avoid confusing the compiler.

提交回复
热议问题