![](https://img-blog.csdnimg.cn/20201014180756757.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
设计模式读书笔记
文章平均质量分 83
崔鹏飞
但行好事 莫问前程
展开
-
简单工厂的最最简单应用(C#)
简单工厂的最最简单应用 using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication1{ class Program { static void Main(string[] args)原创 2008-07-29 23:57:00 · 993 阅读 · 1 评论 -
设计模式---备忘录模式(CSDN没有恢复迹象......)
设计模式---备忘录模式(CSDN没有恢复迹象......) using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ class 人物状态 { private int _血; private int _气;原创 2008-08-18 18:43:00 · 571 阅读 · 0 评论 -
设计模式---职责链模式
2008年08月17日 星期日 下午 04:28using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class Officer { protected Officer myboss原创 2008-08-18 18:46:00 · 586 阅读 · 0 评论 -
设计模式---抽象工厂模式+反射+配置文件
using System;using System.Collections.Generic;using System.Text;using System.Reflection;using System.Configuration;namespace ConsoleApplication1{ internal interface SportMan原创 2008-08-08 19:33:00 · 1903 阅读 · 0 评论 -
设计模式---组合模式(CSDN依然没有恢复迹象......)
设计模式---组合模式(CSDN依然没有恢复迹象......) using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class AbstractCompany { protected String Name;原创 2008-08-18 18:43:00 · 768 阅读 · 0 评论 -
设计模式---单例模式(singleton)
设计模式---单例模式(singleton) using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ class Singleton { private static Singleton s; priva原创 2008-08-18 18:44:00 · 575 阅读 · 0 评论 -
设计模式---命令模式
设计模式---命令模式 using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class Order { protected General general; public Order原创 2008-08-18 18:46:00 · 619 阅读 · 0 评论 -
CSDN被和谐期间的Blog都发到百度空间去了
粘贴回来格式一片混乱,百度似乎还有图床保护?干脆留个地址在这里http://hi.baidu.com/yansuochonglou/blog/calendar/200808原创 2008-08-19 20:09:00 · 618 阅读 · 0 评论 -
设计模式---翻译器模式
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class Expretion { public void Translate(Words w) {原创 2008-08-20 20:49:00 · 927 阅读 · 0 评论 -
设计模式---访问者模式(应该是最后一篇了)
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class Element { public abstract void Accept(Visitor v);原创 2008-08-21 18:00:00 · 721 阅读 · 0 评论 -
设计模式---享元模式
using System;using System.Collections.Generic;using System.Text;using System.Collections;namespace ConsoleApplication1{ class MovieTheater { private Hashtable mov原创 2008-08-19 20:07:00 · 618 阅读 · 0 评论 -
设计模式---中介者模式(打出来是“终结者.......”)
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class FBIAgent { public abstract void SendMessage(st原创 2008-08-18 19:31:00 · 656 阅读 · 0 评论 -
设计模式---状态模式(今天CSDN竟然上不去,暂时发在这里) (从百度空间转回来的)
设计模式---状态模式(今天CSDN竟然上不去,暂时发在这里) using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class State { public abstract void Do原创 2008-08-18 18:02:00 · 789 阅读 · 0 评论 -
装饰模式的简单实现(C#)内有图一张,嘿嘿.....
using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication1{ class Class1 { public static void Main() { Person p = n原创 2008-07-31 21:15:00 · 1713 阅读 · 4 评论 -
策略模式的简单应用(C#)
using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication1{ abstract class OperSuper { public abstract double GetResult(double a,原创 2008-07-30 19:02:00 · 844 阅读 · 1 评论 -
设计模式--代理模式的简单实现(C#)+类关系图
using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication1{ class Class1 { public static void Main() { Pro原创 2008-08-01 21:01:00 · 1473 阅读 · 1 评论 -
设计模式--工厂模式
using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication1{ class Client { public static void Main() { IFa原创 2008-08-02 20:34:00 · 680 阅读 · 1 评论 -
设计模式--模板方法模式(照旧,有类关系图)
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ public class TheFather { public void BaseMethod1() { Console.Wri原创 2008-08-04 19:49:00 · 1016 阅读 · 0 评论 -
设计模式--原型模式(附带类关系图一张)
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ public class Simple:ICloneable { private int field1; private int field2;原创 2008-08-03 21:35:00 · 817 阅读 · 0 评论 -
设计模式--外观模式
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ class Facade { private Func1 field1; private Func2 field2;原创 2008-08-05 17:13:00 · 641 阅读 · 0 评论 -
设计模式---观察者模式(恐怖袭击、地震的例子,有类关系图)
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ internal interface Warning { String Situation {原创 2008-08-07 18:08:00 · 2466 阅读 · 0 评论 -
设计模式---建造者(Builder)模式,有关系图
using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ abstract class Builder { public abstract void SetPrice(); publi原创 2008-08-06 17:56:00 · 934 阅读 · 1 评论 -
Head First C# 中文版 图文皆译 第五章 封装 page200
看看这儿的get和set访问器。使用这个类的窗体含有一个CableBill(有线电视账单)的新实例,叫做thisMonth,它还会通过点击按钮来调用GetThiMonthBill()方法。写出下面代码执行之后amountOwed变量的值。翻译 2009-02-18 17:27:00 · 609 阅读 · 0 评论