Update the parameter values with the set ones from `other`.
(&mut self, other: Self)
| 27 | impl GrpcClientParameters { |
| 28 | /// Update the parameter values with the set ones from `other`. |
| 29 | pub fn update(&mut self, other: Self) { |
| 30 | let Self { |
| 31 | connect_timeout, |
| 32 | http2_keep_alive_interval, |
| 33 | http2_keep_alive_timeout, |
| 34 | } = self; |
| 35 | let Self { |
| 36 | connect_timeout: other_connect_timeout, |
| 37 | http2_keep_alive_interval: other_http2_keep_alive_interval, |
| 38 | http2_keep_alive_timeout: other_http2_keep_alive_timeout, |
| 39 | } = other; |
| 40 | |
| 41 | if let Some(v) = other_connect_timeout { |
| 42 | *connect_timeout = Some(v); |
| 43 | } |
| 44 | if let Some(v) = other_http2_keep_alive_interval { |
| 45 | *http2_keep_alive_interval = Some(v); |
| 46 | } |
| 47 | if let Some(v) = other_http2_keep_alive_timeout { |
| 48 | *http2_keep_alive_timeout = Some(v); |
| 49 | } |
| 50 | } |
| 51 | |
| 52 | /// Return whether all parameters are unset. |
| 53 | pub fn all_unset(&self) -> bool { |
no outgoing calls
no test coverage detected