1
2
3
4
5 package org.epics.pvmanager;
6
7
8
9
10
11
12
13
14
15 public class ChannelWriteRecipe {
16 private final String channelName;
17 private final ChannelHandlerWriteSubscription writeSubscription;
18
19
20
21
22
23
24
25 public ChannelWriteRecipe(String channelName, ChannelHandlerWriteSubscription writeSubscription) {
26 this.channelName = channelName;
27 this.writeSubscription = writeSubscription;
28 }
29
30
31
32
33
34
35 public String getChannelName() {
36 return channelName;
37 }
38
39
40
41
42
43
44 public ChannelHandlerWriteSubscription getWriteSubscription() {
45 return writeSubscription;
46 }
47
48 @Override
49 public int hashCode() {
50 int hash = 5;
51 hash = 71 * hash + (this.channelName != null ? this.channelName.hashCode() : 0);
52 hash = 71 * hash + (this.writeSubscription != null ? this.writeSubscription.hashCode() : 0);
53 return hash;
54 }
55
56 @Override
57 public boolean equals(Object obj) {
58 if (obj == null) {
59 return false;
60 }
61 if (getClass() != obj.getClass()) {
62 return false;
63 }
64 final ChannelWriteRecipe other = (ChannelWriteRecipe) obj;
65 if ((this.channelName == null) ? (other.channelName != null) : !this.channelName.equals(other.channelName)) {
66 return false;
67 }
68 if (this.writeSubscription != other.writeSubscription && (this.writeSubscription == null || !this.writeSubscription.equals(other.writeSubscription))) {
69 return false;
70 }
71 return true;
72 }
73
74 }