pub struct Listen {
pub address: String,
pub public_host: Option<String>,
pub public_port: Option<u16>,
pub friendly_name: Option<String>,
pub roles: Option<NodeRoles>,
pub proxy_protocol: Option<ProxyProtocol>,
}Fields§
§address: String待ち受けるアドレス(0.0.0.0:7900 など)
public_host: Option<String>外から見たホスト名かアドレス。ping で答え、つないだピアに名乗る。なければ空にして、相手に接続元から 決めてもらう
public_port: Option<u16>外から見たポート。ping で答え、つないだピアに名乗る。中継の後ろで、待ち受けるポートと外のポートが違うときに
書く。なければ address のポート
friendly_name: Option<String>ping で答え、名乗るときの名前
roles: Option<NodeRoles>名乗るロール。P2P でも REST の /node/info でもこれを名乗る。0x43 や 67 のような整数か、
[Peer, Api, IPv4] のような catapult の名前の並びで書く。なければ NodeConfig::roles の既定
proxy_protocol: Option<ProxyProtocol>HAProxy や nginx などの中継の後ろで受けるときの、PROXY protocol。なければヘッダーを読まない
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Listen
impl<'de> Deserialize<'de> for Listen
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Listen
impl StructuralPartialEq for Listen
Auto Trait Implementations§
impl Freeze for Listen
impl RefUnwindSafe for Listen
impl Send for Listen
impl Sync for Listen
impl Unpin for Listen
impl UnsafeUnpin for Listen
impl UnwindSafe for Listen
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more