pub struct RewriteRule {
pub matcher: RewriteMatcher,
pub pending: bool,
pub payee: Option<String>,
pub account: Option<String>,
pub conversion: Option<CommodityConversionSpec>,
}Expand description
RewriteRule specifies the rewrite rule matched against transaction.
Fields§
§matcher: RewriteMatchermatcher for the rewrite.
pending: boolSet true to leave the match pending.
payee: Option<String>Payee to be set for the matched transaction.
account: Option<String>Account to be set for the matched transaction.
conversion: Option<CommodityConversionSpec>Commodity (currency) conversion specification.
This field is only used in CSV import, and only applicable when
the transcation has multi commodities. See details for CommodityConversionSpec.
Trait Implementations§
Source§impl Clone for RewriteRule
impl Clone for RewriteRule
Source§fn clone(&self) -> RewriteRule
fn clone(&self) -> RewriteRule
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 RewriteRule
impl Debug for RewriteRule
Source§impl<'de> Deserialize<'de> for RewriteRule
impl<'de> Deserialize<'de> for RewriteRule
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
Source§impl PartialEq for RewriteRule
impl PartialEq for RewriteRule
Source§impl Serialize for RewriteRule
impl Serialize for RewriteRule
impl Eq for RewriteRule
impl StructuralPartialEq for RewriteRule
Auto Trait Implementations§
impl Freeze for RewriteRule
impl RefUnwindSafe for RewriteRule
impl Send for RewriteRule
impl Sync for RewriteRule
impl Unpin for RewriteRule
impl UnwindSafe for RewriteRule
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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