#[non_exhaustive]pub struct UpdateCatalogFileOptions<'a> {
pub target_path: &'a Path,
pub options: UpdateCatalogOptions<'a>,
}Available on crate feature
catalog only.Expand description
Options for updating a catalog file on disk.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.target_path: &'a PathPath to the catalog file that should be read and conditionally written.
options: UpdateCatalogOptions<'a>In-memory update options applied to the file content.
Implementations§
Source§impl<'a> UpdateCatalogFileOptions<'a>
impl<'a> UpdateCatalogFileOptions<'a>
Sourcepub fn new(
target_path: &'a Path,
source_locale: &'a str,
input: impl Into<CatalogUpdateInput>,
) -> UpdateCatalogFileOptions<'a>
pub fn new( target_path: &'a Path, source_locale: &'a str, input: impl Into<CatalogUpdateInput>, ) -> UpdateCatalogFileOptions<'a>
Creates file update options with required fields set.
Optional fields on the nested update options use
UpdateCatalogOptions::new defaults.
Sourcepub fn with_options(
self,
options: UpdateCatalogOptions<'a>,
) -> UpdateCatalogFileOptions<'a>
pub fn with_options( self, options: UpdateCatalogOptions<'a>, ) -> UpdateCatalogFileOptions<'a>
Returns file update options that use the given in-memory update options.
Trait Implementations§
Source§impl<'a> Clone for UpdateCatalogFileOptions<'a>
impl<'a> Clone for UpdateCatalogFileOptions<'a>
Source§fn clone(&self) -> UpdateCatalogFileOptions<'a>
fn clone(&self) -> UpdateCatalogFileOptions<'a>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for UpdateCatalogFileOptions<'a>
impl<'a> Debug for UpdateCatalogFileOptions<'a>
impl<'a> Eq for UpdateCatalogFileOptions<'a>
Source§impl<'a> PartialEq for UpdateCatalogFileOptions<'a>
impl<'a> PartialEq for UpdateCatalogFileOptions<'a>
Source§fn eq(&self, other: &UpdateCatalogFileOptions<'a>) -> bool
fn eq(&self, other: &UpdateCatalogFileOptions<'a>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<'a> StructuralPartialEq for UpdateCatalogFileOptions<'a>
Auto Trait Implementations§
impl<'a> Freeze for UpdateCatalogFileOptions<'a>
impl<'a> RefUnwindSafe for UpdateCatalogFileOptions<'a>
impl<'a> Send for UpdateCatalogFileOptions<'a>
impl<'a> Sync for UpdateCatalogFileOptions<'a>
impl<'a> Unpin for UpdateCatalogFileOptions<'a>
impl<'a> UnsafeUnpin for UpdateCatalogFileOptions<'a>
impl<'a> UnwindSafe for UpdateCatalogFileOptions<'a>
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