added chain of responsibility sample

This commit is contained in:
Ilkka Seppala
2014-08-17 09:05:37 +03:00
parent a53c217f37
commit 9e7db125a8
10 changed files with 189 additions and 0 deletions
@@ -0,0 +1,33 @@
package com.iluwatar;
public class Request {
private String requestDescription;
private RequestType requestType;
public Request(RequestType requestType, String requestDescription) {
this.setRequestType(requestType);
this.setRequestDescription(requestDescription);
}
public String getRequestDescription() {
return requestDescription;
}
public void setRequestDescription(String requestDescription) {
this.requestDescription = requestDescription;
}
public RequestType getRequestType() {
return requestType;
}
public void setRequestType(RequestType requestType) {
this.requestType = requestType;
}
@Override
public String toString() {
return getRequestDescription();
}
}