예제 #1
0
        public string HandleRequest(SoftwareRequest request)
        {
            if (this.CanHandle(request))
            {
              return this.DevelopSoftware(request);
            }

            if (this.Successor != null)
            {
               return this.Successor.HandleRequest(request);
            }

            return "This software cannot be developed by our team";
        }
예제 #2
0
 protected override string DevelopSoftware(SoftwareRequest request)
 {
     return "Software Created by the Regular Developer Team!";
 }
예제 #3
0
 protected override bool CanHandle(SoftwareRequest request)
 {
     return request.Difficulty <= MaximumDifficultyToHandle;
 }
예제 #4
0
 protected abstract string DevelopSoftware(SoftwareRequest request);
예제 #5
0
 protected abstract bool CanHandle(SoftwareRequest request);