开发者

namespaces in custom libraries best practices

开发者 https://www.devze.com 2023-03-24 10:06 出处:网络
Just wondering what the pros and cons between the two following two examples: using MyLib; namespace System.IO

Just wondering what the pros and cons between the two following two examples:

using MyLib;

namespace System.IO
{
    public class IoService : IIoService
    {
    ...

and

using System.IO;
using MyLib;

namespace MyLib.IO
{
    开发者_运维知识库public class IoService : IIoService
    {
    ...


Don't add stuff to library namespaces that aren't yours.

0

精彩评论

暂无评论...
验证码 换一张
取 消