1#[allow(clippy::derive_partial_eq_without_eq)]
5#[derive(Clone, PartialEq, ::prost::Message)]
6pub struct MsgTransfer {
7 #[prost(string, tag = "1")]
9 pub source_port: ::prost::alloc::string::String,
10 #[prost(string, tag = "2")]
12 pub source_channel: ::prost::alloc::string::String,
13 #[prost(message, optional, tag = "3")]
15 pub token: ::core::option::Option<super::super::super::super::cosmos::base::v1beta1::Coin>,
16 #[prost(string, tag = "4")]
18 pub sender: ::prost::alloc::string::String,
19 #[prost(string, tag = "5")]
21 pub receiver: ::prost::alloc::string::String,
22 #[prost(message, optional, tag = "6")]
25 pub timeout_height: ::core::option::Option<super::super::super::core::client::v1::Height>,
26 #[prost(uint64, tag = "7")]
29 pub timeout_timestamp: u64,
30}
31#[allow(clippy::derive_partial_eq_without_eq)]
33#[derive(Clone, PartialEq, ::prost::Message)]
34pub struct MsgTransferResponse {}
35#[cfg(feature = "grpc")]
37#[cfg_attr(docsrs, doc(cfg(feature = "grpc")))]
38pub mod msg_client {
39 #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
40 use tonic::codegen::http::Uri;
41 use tonic::codegen::*;
42 #[derive(Debug, Clone)]
44 pub struct MsgClient<T> {
45 inner: tonic::client::Grpc<T>,
46 }
47 #[cfg(feature = "grpc-transport")]
48 #[cfg_attr(docsrs, doc(cfg(feature = "grpc-transport")))]
49 impl MsgClient<tonic::transport::Channel> {
50 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
52 where
53 D: std::convert::TryInto<tonic::transport::Endpoint>,
54 D::Error: Into<StdError>,
55 {
56 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
57 Ok(Self::new(conn))
58 }
59 }
60 impl<T> MsgClient<T>
61 where
62 T: tonic::client::GrpcService<tonic::body::BoxBody>,
63 T::Error: Into<StdError>,
64 T::ResponseBody: Body<Data = Bytes> + Send + 'static,
65 <T::ResponseBody as Body>::Error: Into<StdError> + Send,
66 {
67 pub fn new(inner: T) -> Self {
68 let inner = tonic::client::Grpc::new(inner);
69 Self { inner }
70 }
71 pub fn with_origin(inner: T, origin: Uri) -> Self {
72 let inner = tonic::client::Grpc::with_origin(inner, origin);
73 Self { inner }
74 }
75 pub fn with_interceptor<F>(inner: T, interceptor: F) -> MsgClient<InterceptedService<T, F>>
76 where
77 F: tonic::service::Interceptor,
78 T::ResponseBody: Default,
79 T: tonic::codegen::Service<
80 http::Request<tonic::body::BoxBody>,
81 Response = http::Response<
82 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
83 >,
84 >,
85 <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error:
86 Into<StdError> + Send + Sync,
87 {
88 MsgClient::new(InterceptedService::new(inner, interceptor))
89 }
90 #[must_use]
95 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
96 self.inner = self.inner.send_compressed(encoding);
97 self
98 }
99 #[must_use]
101 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
102 self.inner = self.inner.accept_compressed(encoding);
103 self
104 }
105 pub async fn transfer(
107 &mut self,
108 request: impl tonic::IntoRequest<super::MsgTransfer>,
109 ) -> Result<tonic::Response<super::MsgTransferResponse>, tonic::Status> {
110 self.inner.ready().await.map_err(|e| {
111 tonic::Status::new(
112 tonic::Code::Unknown,
113 format!("Service was not ready: {}", e.into()),
114 )
115 })?;
116 let codec = tonic::codec::ProstCodec::default();
117 let path =
118 http::uri::PathAndQuery::from_static("/ibc.applications.transfer.v1.Msg/Transfer");
119 self.inner.unary(request.into_request(), path, codec).await
120 }
121 }
122}
123#[allow(clippy::derive_partial_eq_without_eq)]
126#[derive(Clone, PartialEq, ::prost::Message)]
127pub struct DenomTrace {
128 #[prost(string, tag = "1")]
131 pub path: ::prost::alloc::string::String,
132 #[prost(string, tag = "2")]
134 pub base_denom: ::prost::alloc::string::String,
135}
136#[allow(clippy::derive_partial_eq_without_eq)]
141#[derive(Clone, PartialEq, ::prost::Message)]
142pub struct Params {
143 #[prost(bool, tag = "1")]
146 pub send_enabled: bool,
147 #[prost(bool, tag = "2")]
150 pub receive_enabled: bool,
151}
152#[allow(clippy::derive_partial_eq_without_eq)]
155#[derive(Clone, PartialEq, ::prost::Message)]
156pub struct QueryDenomTraceRequest {
157 #[prost(string, tag = "1")]
159 pub hash: ::prost::alloc::string::String,
160}
161#[allow(clippy::derive_partial_eq_without_eq)]
164#[derive(Clone, PartialEq, ::prost::Message)]
165pub struct QueryDenomTraceResponse {
166 #[prost(message, optional, tag = "1")]
168 pub denom_trace: ::core::option::Option<DenomTrace>,
169}
170#[allow(clippy::derive_partial_eq_without_eq)]
173#[derive(Clone, PartialEq, ::prost::Message)]
174pub struct QueryDenomTracesRequest {
175 #[prost(message, optional, tag = "1")]
177 pub pagination: ::core::option::Option<
178 super::super::super::super::cosmos::base::query::v1beta1::PageRequest,
179 >,
180}
181#[allow(clippy::derive_partial_eq_without_eq)]
184#[derive(Clone, PartialEq, ::prost::Message)]
185pub struct QueryDenomTracesResponse {
186 #[prost(message, repeated, tag = "1")]
188 pub denom_traces: ::prost::alloc::vec::Vec<DenomTrace>,
189 #[prost(message, optional, tag = "2")]
191 pub pagination: ::core::option::Option<
192 super::super::super::super::cosmos::base::query::v1beta1::PageResponse,
193 >,
194}
195#[allow(clippy::derive_partial_eq_without_eq)]
197#[derive(Clone, PartialEq, ::prost::Message)]
198pub struct QueryParamsRequest {}
199#[allow(clippy::derive_partial_eq_without_eq)]
201#[derive(Clone, PartialEq, ::prost::Message)]
202pub struct QueryParamsResponse {
203 #[prost(message, optional, tag = "1")]
205 pub params: ::core::option::Option<Params>,
206}
207#[allow(clippy::derive_partial_eq_without_eq)]
210#[derive(Clone, PartialEq, ::prost::Message)]
211pub struct QueryDenomHashRequest {
212 #[prost(string, tag = "1")]
214 pub trace: ::prost::alloc::string::String,
215}
216#[allow(clippy::derive_partial_eq_without_eq)]
219#[derive(Clone, PartialEq, ::prost::Message)]
220pub struct QueryDenomHashResponse {
221 #[prost(string, tag = "1")]
223 pub hash: ::prost::alloc::string::String,
224}
225#[cfg(feature = "grpc")]
227#[cfg_attr(docsrs, doc(cfg(feature = "grpc")))]
228pub mod query_client {
229 #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
230 use tonic::codegen::http::Uri;
231 use tonic::codegen::*;
232 #[derive(Debug, Clone)]
234 pub struct QueryClient<T> {
235 inner: tonic::client::Grpc<T>,
236 }
237 #[cfg(feature = "grpc-transport")]
238 #[cfg_attr(docsrs, doc(cfg(feature = "grpc-transport")))]
239 impl QueryClient<tonic::transport::Channel> {
240 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
242 where
243 D: std::convert::TryInto<tonic::transport::Endpoint>,
244 D::Error: Into<StdError>,
245 {
246 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
247 Ok(Self::new(conn))
248 }
249 }
250 impl<T> QueryClient<T>
251 where
252 T: tonic::client::GrpcService<tonic::body::BoxBody>,
253 T::Error: Into<StdError>,
254 T::ResponseBody: Body<Data = Bytes> + Send + 'static,
255 <T::ResponseBody as Body>::Error: Into<StdError> + Send,
256 {
257 pub fn new(inner: T) -> Self {
258 let inner = tonic::client::Grpc::new(inner);
259 Self { inner }
260 }
261 pub fn with_origin(inner: T, origin: Uri) -> Self {
262 let inner = tonic::client::Grpc::with_origin(inner, origin);
263 Self { inner }
264 }
265 pub fn with_interceptor<F>(
266 inner: T,
267 interceptor: F,
268 ) -> QueryClient<InterceptedService<T, F>>
269 where
270 F: tonic::service::Interceptor,
271 T::ResponseBody: Default,
272 T: tonic::codegen::Service<
273 http::Request<tonic::body::BoxBody>,
274 Response = http::Response<
275 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
276 >,
277 >,
278 <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error:
279 Into<StdError> + Send + Sync,
280 {
281 QueryClient::new(InterceptedService::new(inner, interceptor))
282 }
283 #[must_use]
288 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
289 self.inner = self.inner.send_compressed(encoding);
290 self
291 }
292 #[must_use]
294 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
295 self.inner = self.inner.accept_compressed(encoding);
296 self
297 }
298 pub async fn denom_trace(
300 &mut self,
301 request: impl tonic::IntoRequest<super::QueryDenomTraceRequest>,
302 ) -> Result<tonic::Response<super::QueryDenomTraceResponse>, tonic::Status> {
303 self.inner.ready().await.map_err(|e| {
304 tonic::Status::new(
305 tonic::Code::Unknown,
306 format!("Service was not ready: {}", e.into()),
307 )
308 })?;
309 let codec = tonic::codec::ProstCodec::default();
310 let path = http::uri::PathAndQuery::from_static(
311 "/ibc.applications.transfer.v1.Query/DenomTrace",
312 );
313 self.inner.unary(request.into_request(), path, codec).await
314 }
315 pub async fn denom_traces(
317 &mut self,
318 request: impl tonic::IntoRequest<super::QueryDenomTracesRequest>,
319 ) -> Result<tonic::Response<super::QueryDenomTracesResponse>, tonic::Status> {
320 self.inner.ready().await.map_err(|e| {
321 tonic::Status::new(
322 tonic::Code::Unknown,
323 format!("Service was not ready: {}", e.into()),
324 )
325 })?;
326 let codec = tonic::codec::ProstCodec::default();
327 let path = http::uri::PathAndQuery::from_static(
328 "/ibc.applications.transfer.v1.Query/DenomTraces",
329 );
330 self.inner.unary(request.into_request(), path, codec).await
331 }
332 pub async fn params(
334 &mut self,
335 request: impl tonic::IntoRequest<super::QueryParamsRequest>,
336 ) -> Result<tonic::Response<super::QueryParamsResponse>, tonic::Status> {
337 self.inner.ready().await.map_err(|e| {
338 tonic::Status::new(
339 tonic::Code::Unknown,
340 format!("Service was not ready: {}", e.into()),
341 )
342 })?;
343 let codec = tonic::codec::ProstCodec::default();
344 let path =
345 http::uri::PathAndQuery::from_static("/ibc.applications.transfer.v1.Query/Params");
346 self.inner.unary(request.into_request(), path, codec).await
347 }
348 pub async fn denom_hash(
350 &mut self,
351 request: impl tonic::IntoRequest<super::QueryDenomHashRequest>,
352 ) -> Result<tonic::Response<super::QueryDenomHashResponse>, tonic::Status> {
353 self.inner.ready().await.map_err(|e| {
354 tonic::Status::new(
355 tonic::Code::Unknown,
356 format!("Service was not ready: {}", e.into()),
357 )
358 })?;
359 let codec = tonic::codec::ProstCodec::default();
360 let path = http::uri::PathAndQuery::from_static(
361 "/ibc.applications.transfer.v1.Query/DenomHash",
362 );
363 self.inner.unary(request.into_request(), path, codec).await
364 }
365 }
366}
367#[allow(clippy::derive_partial_eq_without_eq)]
369#[derive(Clone, PartialEq, ::prost::Message)]
370pub struct GenesisState {
371 #[prost(string, tag = "1")]
372 pub port_id: ::prost::alloc::string::String,
373 #[prost(message, repeated, tag = "2")]
374 pub denom_traces: ::prost::alloc::vec::Vec<DenomTrace>,
375 #[prost(message, optional, tag = "3")]
376 pub params: ::core::option::Option<Params>,
377}