Last active
January 22, 2019 11:01
-
-
Save MarcoNicolodi/8cf0ea17a7ffd23241b9017426573a4a to your computer and use it in GitHub Desktop.
Chain of responsibility
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public abstract class RuleHandler { | |
private RuleHandler _nextRule; | |
public RuleHandler NextRule (RuleHandler nextRule) { | |
_nextRule = nextRule; | |
return nextRule; | |
} | |
public virtual Label Run (Request request) => _nextRule.Run(request); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment