rocketmq_remoting/protocol/header/
message_operation_header.rs

1/*
2 * Licensed to the Apache Software Foundation (ASF) under one or more
3 * contributor license agreements.  See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License.  You may obtain a copy of the License at
8 *
9 *     http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17use cheetah_string::CheetahString;
18
19pub mod send_message_request_header;
20pub mod send_message_request_header_v2;
21pub mod send_message_response_header;
22
23pub trait TopicRequestHeaderTrait: Sync + Send {
24    fn set_lo(&mut self, lo: Option<bool>);
25
26    fn lo(&self) -> Option<bool>;
27
28    fn set_topic(&mut self, topic: CheetahString);
29
30    fn topic(&self) -> &CheetahString;
31
32    fn broker_name(&self) -> Option<&CheetahString>;
33
34    fn set_broker_name(&mut self, broker_name: CheetahString);
35
36    fn namespace(&self) -> Option<&str>;
37
38    fn set_namespace(&mut self, namespace: CheetahString);
39
40    fn namespaced(&self) -> Option<bool>;
41
42    fn set_namespaced(&mut self, namespaced: bool);
43
44    fn oneway(&self) -> Option<bool>;
45
46    fn set_oneway(&mut self, oneway: bool);
47
48    fn queue_id(&self) -> i32;
49
50    fn set_queue_id(&mut self, queue_id: i32);
51}