1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.asteriskjava.manager.event;
18
19 /***
20 * A RenameEvent is triggered when the name of a channel is changed.
21 * <p>
22 * It is implemented in <code>channel.c</code>
23 *
24 * @author srt
25 * @version $Id: RenameEvent.java 590 2007-01-21 12:01:04Z srt $
26 */
27 public class RenameEvent extends ManagerEvent
28 {
29 /***
30 * Serializable version identifier
31 */
32 static final long serialVersionUID = 3400165738000349767L;
33
34 /***
35 * Old name of the channel before renaming occured.
36 */
37 protected String oldname;
38
39 /***
40 * New name of the channel after renaming occured.
41 */
42 protected String newname;
43
44 /***
45 * New unique id.
46 */
47 protected String newUniqueId;
48
49 /***
50 * Unique id of the channel.
51 */
52 protected String uniqueId;
53
54 /***
55 * @param source
56 */
57 public RenameEvent(Object source)
58 {
59 super(source);
60 }
61
62 /***
63 * Returns the new name of the channel.
64 *
65 * @return the new name of the channel.
66 */
67 public final String getNewname()
68 {
69 return newname;
70 }
71
72 /***
73 * Sets the new name of the channel.
74 *
75 * @param newname the new name of the channel.
76 */
77 public final void setNewname(final String newname)
78 {
79 this.newname = newname;
80 }
81
82 /***
83 * Returns the old name of the channel.
84 *
85 * @return the old name of the channel.
86 */
87 public final String getOldname()
88 {
89 return oldname;
90 }
91
92 /***
93 * Sets the old name of the channel.
94 *
95 * @param oldname the old name of the channel.
96 */
97 public final void setOldname(final String oldname)
98 {
99 this.oldname = oldname;
100 }
101
102 /***
103 * Returns the unique id of the channel.
104 *
105 * @return the unique id of the channel.
106 */
107 public final String getUniqueId()
108 {
109 return uniqueId;
110 }
111
112 /***
113 * Sets the unique id of the channel.
114 *
115 * @param uniqueId the unique id of the channel.
116 */
117 public final void setUniqueId(final String uniqueId)
118 {
119 this.uniqueId = uniqueId;
120 }
121
122 /***
123 * Returns the new unique id of the channel.
124 * <p>
125 * This property is only available on BRIstuffed Asterisk servers.
126 * <p>
127 * The purpose of this property is unclear as the unique id is supposed to
128 * never change.
129 *
130 * @return the new unique id of the channel.
131 * @since 0.3
132 */
133 public final String getNewUniqueId()
134 {
135 return newUniqueId;
136 }
137
138 /***
139 * Sets the new unique id of the channel.
140 * <p>
141 * This property is only available on BRIstuffed Asterisk servers.
142 * <p>
143 * The purpose of this property is unclear as the unique id is supposed to
144 * never change.
145 *
146 * @param newUniqueId the new unique id of the channel.
147 * @since 0.3
148 */
149 public final void setNewUniqueId(final String newUniqueId)
150 {
151 this.newUniqueId = newUniqueId;
152 }
153 }