1
2
3
4
5
6
7
8
9
10
11
12
13
14 package uk.nhs.interoperability.transport;
15
16
17
18
19
20
21
22
23 public class ITKTransportRouteImpl implements ITKTransportRoute {
24
25
26 private String transportType;
27
28
29 private String physicalAddress;
30
31
32 private String replyToAddress;
33
34
35 private String exceptionToAddress;
36
37
38 private String destinationType;
39
40
41 private String wrapperType = ITKTransportRoute.NO_WRAPPER;
42
43
44 private int timeToLive;
45
46
47
48
49 @Override
50 public String getTransportType() {
51 return transportType;
52 }
53
54
55
56
57 @Override
58 public String getPhysicalAddress() {
59 return physicalAddress;
60 }
61
62
63
64
65
66
67
68 public ITKTransportRouteImpl(String type, String address) {
69 this.transportType = type;
70 this.physicalAddress = address;
71 }
72
73
74
75
76
77
78
79
80
81
82
83
84 public ITKTransportRouteImpl(String type, String address, String replyTo,
85 String exceptionTo, String destinationType,
86 String wrapperType, int timeToLive){
87 this.transportType = type;
88 this.physicalAddress = address;
89 this.replyToAddress = replyTo;
90 this.exceptionToAddress = exceptionTo;
91 this.destinationType = destinationType;
92 this.wrapperType = wrapperType;
93 this.timeToLive = timeToLive;
94 }
95
96
97
98
99 @Override
100 public String getReplyToAddress() {
101 return replyToAddress;
102 }
103
104
105
106
107 @Override
108 public String getExceptionToAddress() {
109 return exceptionToAddress;
110 }
111
112
113
114
115 @Override
116 public String getDestinationType() {
117 return destinationType;
118 }
119
120
121
122
123 @Override
124 public String getWrapperType() {
125 return wrapperType;
126 }
127
128
129
130
131 @Override
132 public void setWrapperType(String wrapperType) {
133 this.wrapperType = wrapperType;
134 }
135
136
137
138
139 @Override
140 public int getTimeToLive() {
141 return timeToLive;
142 }
143
144
145
146
147 @Override
148 public String toString() {
149 return "[" + this.getClass().getCanonicalName() + "]"
150 + "\n\tTransport type " + this.getTransportType()
151 + "\n\tPhysical address " + this.getPhysicalAddress()
152 + "\n\tWrapper type " + this.getWrapperType();
153 }
154
155
156 }