pub struct Printer<R: Runtime> { /* private fields */ }Expand description
Rust-side access to the printer APIs.
Implementations§
Source§impl<R: Runtime> Printer<R>
impl<R: Runtime> Printer<R>
pub fn get_printers(&self) -> Result<Vec<PrinterItem>>
pub fn get_printer(&self, id: &str) -> Result<PrinterItem>
pub fn get_printer_by_name(&self, name: &str) -> Result<PrinterItem>
pub fn get_default_printer(&self) -> Result<Option<PrinterItem>>
pub fn set_default_printer(&self, name: &str) -> Result<PrinterItem>
pub fn get_printer_capabilities( &self, name: &str, ) -> Result<PrinterCapabilities>
pub fn get_jobs(&self, printer_name: &str) -> Result<Vec<PrintJob>>
pub fn get_job(&self, printer_name: &str, job_id: i32) -> Result<PrintJob>
pub fn resume_job(&self, printer_name: &str, job_id: i32) -> Result<PrintResult>
pub fn restart_job( &self, printer_name: &str, job_id: i32, ) -> Result<PrintResult>
pub fn pause_job(&self, printer_name: &str, job_id: i32) -> Result<PrintResult>
pub fn remove_job(&self, printer_name: &str, job_id: i32) -> Result<PrintResult>
pub fn print_pdf( &self, printer_name: Option<&str>, path: &Path, settings: &str, remove_after_print: bool, ) -> Result<PrintResult>
pub fn print_pdf_data( &self, printer_name: Option<&str>, data: &str, settings: &str, ) -> Result<PrintResult>
Auto Trait Implementations§
impl<R> Freeze for Printer<R>
impl<R> RefUnwindSafe for Printer<R>
impl<R> Send for Printer<R>
impl<R> Sync for Printer<R>
impl<R> Unpin for Printer<R>
impl<R> UnsafeUnpin for Printer<R>
impl<R> UnwindSafe for Printer<R>
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