|
1 | | -package com.iluwatar.chain; |
2 | | - |
3 | | -public class Request { |
4 | | - |
5 | | - private String requestDescription; |
6 | | - private RequestType requestType; |
7 | | - |
8 | | - public Request(RequestType requestType, String requestDescription) { |
9 | | - this.setRequestType(requestType); |
10 | | - this.setRequestDescription(requestDescription); |
11 | | - } |
12 | | - |
13 | | - public String getRequestDescription() { |
14 | | - return requestDescription; |
15 | | - } |
16 | | - |
17 | | - public void setRequestDescription(String requestDescription) { |
18 | | - this.requestDescription = requestDescription; |
19 | | - } |
20 | | - |
21 | | - public RequestType getRequestType() { |
22 | | - return requestType; |
23 | | - } |
24 | | - |
25 | | - public void setRequestType(RequestType requestType) { |
26 | | - this.requestType = requestType; |
27 | | - } |
28 | | - |
29 | | - @Override |
30 | | - public String toString() { |
31 | | - return getRequestDescription(); |
32 | | - } |
33 | | -} |
| 1 | +package com.iluwatar.chain; |
| 2 | + |
| 3 | +/** |
| 4 | + * |
| 5 | + * Request |
| 6 | + * |
| 7 | + */ |
| 8 | +public class Request { |
| 9 | + |
| 10 | + private String requestDescription; |
| 11 | + private RequestType requestType; |
| 12 | + |
| 13 | + public Request(RequestType requestType, String requestDescription) { |
| 14 | + this.setRequestType(requestType); |
| 15 | + this.setRequestDescription(requestDescription); |
| 16 | + } |
| 17 | + |
| 18 | + public String getRequestDescription() { |
| 19 | + return requestDescription; |
| 20 | + } |
| 21 | + |
| 22 | + public void setRequestDescription(String requestDescription) { |
| 23 | + this.requestDescription = requestDescription; |
| 24 | + } |
| 25 | + |
| 26 | + public RequestType getRequestType() { |
| 27 | + return requestType; |
| 28 | + } |
| 29 | + |
| 30 | + public void setRequestType(RequestType requestType) { |
| 31 | + this.requestType = requestType; |
| 32 | + } |
| 33 | + |
| 34 | + @Override |
| 35 | + public String toString() { |
| 36 | + return getRequestDescription(); |
| 37 | + } |
| 38 | +} |
0 commit comments