@@ -121,12 +121,28 @@ namespace Aws
121
121
/* *
122
122
* Default constructor
123
123
*/
124
- IncomingPublishEvent () : m_payload() { AWS_ZERO_STRUCT (m_payload); }
124
+ IncomingPublishEvent () : m_topic(), m_payload()
125
+ {
126
+ AWS_ZERO_STRUCT (m_topic);
127
+ AWS_ZERO_STRUCT (m_payload);
128
+ }
129
+
130
+ /* *
131
+ * Sets the message response topic associated with this event. The event does not own this topic.
132
+ *
133
+ * @param topic the message response topic associated with this event
134
+ * @return reference to this
135
+ */
136
+ IncomingPublishEvent &WithTopic (Aws::Crt::ByteCursor topic)
137
+ {
138
+ m_topic = topic;
139
+ return *this ;
140
+ }
125
141
126
142
/* *
127
143
* Sets the message payload associated with this event. The event does not own this payload.
128
144
*
129
- * @param payload he message payload associated with this event
145
+ * @param payload the message payload associated with this event
130
146
* @return reference to this
131
147
*/
132
148
IncomingPublishEvent &WithPayload (Aws::Crt::ByteCursor payload)
@@ -135,6 +151,13 @@ namespace Aws
135
151
return *this ;
136
152
}
137
153
154
+ /* *
155
+ * Gets the message response topic associated with this event.
156
+ *
157
+ * @return the message response topic associated with this event
158
+ */
159
+ Aws::Crt::ByteCursor GetTopic () const { return m_topic; }
160
+
138
161
/* *
139
162
* Gets the message payload associated with this event.
140
163
*
@@ -143,6 +166,7 @@ namespace Aws
143
166
Aws::Crt::ByteCursor GetPayload () const { return m_payload; }
144
167
145
168
private:
169
+ Aws::Crt::ByteCursor m_topic;
146
170
Aws::Crt::ByteCursor m_payload;
147
171
};
148
172
0 commit comments