namespace (C# Study)
http://csharpstudy.com/CSharp/CSharp-namespace.aspx
namespace (Hoons.net)
http://www.hoons.kr/Lecture/LectureMain.aspx?BoardIdx=43000&kind=53&view=0
namespace (Winapi)
http://www.winapi.co.kr/dotnet/book/2-3-1.htm
using System;
namespace ConsoleApplication1
{
namespace A
{
class MyClass
{
int value = 1;
public void MyMethod() { System.Console.WriteLine(value); }
}
}
namespace B
{
class MyClass
{
double value = 2.1;
public void MyMethod() { System.Console.WriteLine(value); }
}
}
class Program
{
static void Main(string[] args)
{
A.MyClass a = new A.MyClass();
a.MyMethod(); // 1 출력
B.MyClass b = new B.MyClass();
b.MyMethod(); // 2.1 출력
}
}
}