GmsDocumentScanningResult

  • GmsDocumentScanningResult stores the result of a document scanning operation, potentially including scanned pages and a PDF.

  • You can retrieve an instance of this class from the Activity result data using fromActivityResultIntent.

  • Access the scanned pages using getPages() if JPEG output was specified in the scanner options.

  • Obtain the PDF result with getPdf() if PDF output was specified in the scanner options.

public abstract class GmsDocumentScanningResult extends Object
implements Parcelable

Result for document scanning.

Nested Class Summary

class GmsDocumentScanningResult.Page Represents a page in the scanning result. 
class GmsDocumentScanningResult.Pdf Represents the PDF in the scanning result. 

Inherited Constant Summary

Public Constructor Summary

Public Method Summary

static GmsDocumentScanningResult
fromActivityResultIntent(Intent data)
Gets the GmsDocumentScanningResult from the scanning Activity result data.
abstract List<GmsDocumentScanningResult.Page>
getPages()
Returns the scanned pages or null if GmsDocumentScannerOptions.RESULT_FORMAT_JPEG was not specified when creating the scanner options.
abstract GmsDocumentScanningResult.Pdf
getPdf()
Returns the PDF result or null if GmsDocumentScannerOptions.RESULT_FORMAT_PDF was not specified when creating the scanner options.

Inherited Method Summary

Public Constructors

public GmsDocumentScanningResult ()

Public Methods

public static GmsDocumentScanningResult fromActivityResultIntent (Intent data)

Gets the GmsDocumentScanningResult from the scanning Activity result data.

Returns null if fails to extract or construct the result.

public abstract List<GmsDocumentScanningResult.Page> getPages ()

Returns the scanned pages or null if GmsDocumentScannerOptions.RESULT_FORMAT_JPEG was not specified when creating the scanner options.

public abstract GmsDocumentScanningResult.Pdf getPdf ()

Returns the PDF result or null if GmsDocumentScannerOptions.RESULT_FORMAT_PDF was not specified when creating the scanner options.