pub struct Link(/* private fields */);
Expand description
Transaction link
§Example
let input = r#"
2014-02-05 * "Invoice for January" ^invoice-pepe-studios-jan14
Income:Clients:PepeStudios -8450.00 USD
Assets:AccountsReceivable
"#;
let beancount: BeancountFile<f64> = input.parse().unwrap();
let DirectiveContent::Transaction(trx) = &beancount.directives[0].content else {
unreachable!("was not a transaction")
};
assert!(trx.links.contains("invoice-pepe-studios-jan14"));
Implementations§
Trait Implementations§
Source§impl Ord for Link
impl Ord for Link
Source§impl PartialOrd for Link
impl PartialOrd for Link
impl Eq for Link
impl StructuralPartialEq for Link
Auto Trait Implementations§
impl Freeze for Link
impl RefUnwindSafe for Link
impl Send for Link
impl Sync for Link
impl Unpin for Link
impl UnwindSafe for Link
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