标签:style blog http color io os ar strong sp
static void DrawShape(Shape s) { if (s is Rectangle) DrawRectange(s as Rectangle); else if (s is Square) DrawSquare(s as Square); else { // ... } }
标签:style blog http color io os ar strong sp
原文地址:http://www.cnblogs.com/fecktty2013/p/software-design-solid.html