pub struct PatternExporter;Expand description
Exports and imports refactoring patterns
Implementations§
Source§impl PatternExporter
impl PatternExporter
Sourcepub fn export_json(pattern: &RefactoringPattern) -> Result<String>
pub fn export_json(pattern: &RefactoringPattern) -> Result<String>
Export a pattern to JSON format
Sourcepub fn export_yaml(pattern: &RefactoringPattern) -> Result<String>
pub fn export_yaml(pattern: &RefactoringPattern) -> Result<String>
Export a pattern to YAML format
Sourcepub fn import_json(data: &str) -> Result<RefactoringPattern>
pub fn import_json(data: &str) -> Result<RefactoringPattern>
Import a pattern from JSON format
Sourcepub fn import_yaml(data: &str) -> Result<RefactoringPattern>
pub fn import_yaml(data: &str) -> Result<RefactoringPattern>
Import a pattern from YAML format
Sourcepub fn export_patterns_json(patterns: &[RefactoringPattern]) -> Result<String>
pub fn export_patterns_json(patterns: &[RefactoringPattern]) -> Result<String>
Export multiple patterns to JSON format
Sourcepub fn export_patterns_yaml(patterns: &[RefactoringPattern]) -> Result<String>
pub fn export_patterns_yaml(patterns: &[RefactoringPattern]) -> Result<String>
Export multiple patterns to YAML format
Sourcepub fn import_patterns_json(data: &str) -> Result<Vec<RefactoringPattern>>
pub fn import_patterns_json(data: &str) -> Result<Vec<RefactoringPattern>>
Import multiple patterns from JSON format
Sourcepub fn import_patterns_yaml(data: &str) -> Result<Vec<RefactoringPattern>>
pub fn import_patterns_yaml(data: &str) -> Result<Vec<RefactoringPattern>>
Import multiple patterns from YAML format
Auto Trait Implementations§
impl Freeze for PatternExporter
impl RefUnwindSafe for PatternExporter
impl Send for PatternExporter
impl Sync for PatternExporter
impl Unpin for PatternExporter
impl UnwindSafe for PatternExporter
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