CoroutinePrintDocumentAdapter
A PrintDocumentAdapter that exposes onLayout and onWrite functions as suspend functions that will automatically invoke the correct callback methods.
Inheritors
Functions
Link copied to clipboard
abstract suspend fun onLayout(oldAttributes: PrintAttributes?, newAttributes: PrintAttributes, extras: Bundle?): PrintDocumentInfo
override fun onLayout(oldAttributes: PrintAttributes?, newAttributes: PrintAttributes, cancellationSignal: CancellationSignal, callback: PrintDocumentAdapter.LayoutResultCallback, extras: Bundle?)
Link copied to clipboard
abstract suspend fun onWrite(pages: Array<out PageRange>, destination: ParcelFileDescriptor): Array<out PageRange>
override fun onWrite(pages: Array<out PageRange>, destination: ParcelFileDescriptor, cancellationSignal: CancellationSignal, callback: PrintDocumentAdapter.WriteResultCallback)