pub struct OnchainPolicy {
pub filter: PolicyFilter,
pub min_funding_depth: u16,
}
Expand description
Policy to configure the onchain validator
Fields§
§filter: PolicyFilter
Policy filter
min_funding_depth: u16
Minimum funding confirmations
Trait Implementations§
Source§impl Policy for OnchainPolicy
impl Policy for OnchainPolicy
Source§fn policy_error(&self, tag: String, msg: String) -> Result<(), ValidationError>
fn policy_error(&self, tag: String, msg: String) -> Result<(), ValidationError>
A policy error has occurred.
Policy errors can be converted to warnings by returning
Ok(())
Source§fn temporary_policy_error(
&self,
tag: String,
msg: String,
) -> Result<(), ValidationError>
fn temporary_policy_error( &self, tag: String, msg: String, ) -> Result<(), ValidationError>
A temporary policy error has occurred.
Policy errors can be converted to warnings by returning
Ok(())
Source§fn policy_log(&self, _tag: String, msg: String)
fn policy_log(&self, _tag: String, msg: String)
Log at ERROR or WARN matching the policy error handling
Source§fn global_velocity_control(&self) -> VelocityControlSpec
fn global_velocity_control(&self) -> VelocityControlSpec
Velocity control to apply to the entire node
Source§fn fee_velocity_control(&self) -> VelocityControlSpec
fn fee_velocity_control(&self) -> VelocityControlSpec
Velocity control to apply to L1 fees paid by the node
Source§fn max_channels(&self) -> usize
fn max_channels(&self) -> usize
Maximum number of concurrent channels
Source§fn max_invoices(&self) -> usize
fn max_invoices(&self) -> usize
Maximum number of concurrent invoices (issued and approved)
Auto Trait Implementations§
impl Freeze for OnchainPolicy
impl RefUnwindSafe for OnchainPolicy
impl Send for OnchainPolicy
impl Sync for OnchainPolicy
impl Unpin for OnchainPolicy
impl UnwindSafe for OnchainPolicy
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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