pub struct TypedFieldMapping<S> {
pub target_path: String,
pub source: MappingSource,
pub transform: Option<Transformation>,
pub population: PopulationStrategy,
pub condition: Option<ConditionExpr>,
pub when: Option<String>,
pub stop: Option<String>,
pub emit: bool,
/* private fields */
}Fields§
§target_path: String§source: MappingSource§transform: Option<Transformation>§population: PopulationStrategy§condition: Option<ConditionExpr>§when: Option<String>§stop: Option<String>§emit: boolImplementations§
Source§impl<S> TypedFieldMapping<S>
impl<S> TypedFieldMapping<S>
pub fn new( target_path: String, source: MappingSource, population: PopulationStrategy, ) -> Self
pub fn with_transform(self, transform: Transformation) -> Self
pub fn with_condition(self, condition: ConditionExpr) -> Self
pub fn with_when(self, when: String) -> Self
pub fn with_stop(self, stop: String) -> Self
pub fn with_emit(self, emit: bool) -> Self
Sourcepub fn to_serializable(&self) -> SerializableFieldMapping
pub fn to_serializable(&self) -> SerializableFieldMapping
Convert to serializable format
Sourcepub fn from_serializable(mapping: SerializableFieldMapping) -> Self
pub fn from_serializable(mapping: SerializableFieldMapping) -> Self
Create from serializable format
Trait Implementations§
Source§impl<S: Clone> Clone for TypedFieldMapping<S>
impl<S: Clone> Clone for TypedFieldMapping<S>
Auto Trait Implementations§
impl<S> Freeze for TypedFieldMapping<S>where
PhantomData<S>: Freeze,
impl<S> RefUnwindSafe for TypedFieldMapping<S>where
PhantomData<S>: RefUnwindSafe,
impl<S> Send for TypedFieldMapping<S>where
PhantomData<S>: Send,
impl<S> Sync for TypedFieldMapping<S>where
PhantomData<S>: Sync,
impl<S> Unpin for TypedFieldMapping<S>where
PhantomData<S>: Unpin,
impl<S> UnsafeUnpin for TypedFieldMapping<S>where
PhantomData<S>: UnsafeUnpin,
impl<S> UnwindSafe for TypedFieldMapping<S>where
PhantomData<S>: UnwindSafe,
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