pub enum PortfolioWeightError {
NonFiniteWeight,
EmptyAssetId,
DuplicateAssetId(String),
NonFiniteTolerance,
NegativeTolerance,
}Expand description
Errors returned by portfolio weight helpers.
Variants§
NonFiniteWeight
Weight values must be finite.
EmptyAssetId
Asset identifiers must be non-empty after trimming whitespace.
DuplicateAssetId(String)
Asset identifiers must be unique in a weight set.
NonFiniteTolerance
Tolerances must be finite.
NegativeTolerance
Tolerances must not be negative.
Trait Implementations§
Source§impl Clone for PortfolioWeightError
impl Clone for PortfolioWeightError
Source§fn clone(&self) -> PortfolioWeightError
fn clone(&self) -> PortfolioWeightError
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PortfolioWeightError
impl Debug for PortfolioWeightError
Source§impl Display for PortfolioWeightError
impl Display for PortfolioWeightError
Source§impl Error for PortfolioWeightError
impl Error for PortfolioWeightError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl PartialEq for PortfolioWeightError
impl PartialEq for PortfolioWeightError
impl Eq for PortfolioWeightError
impl StructuralPartialEq for PortfolioWeightError
Auto Trait Implementations§
impl Freeze for PortfolioWeightError
impl RefUnwindSafe for PortfolioWeightError
impl Send for PortfolioWeightError
impl Sync for PortfolioWeightError
impl Unpin for PortfolioWeightError
impl UnsafeUnpin for PortfolioWeightError
impl UnwindSafe for PortfolioWeightError
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