DataModel

A base class containing images for a scanned document

import com.sybrin.documentscanner.models.DataModel

Summary

Public methods

castToModel

public <T extends DocumentModel> castToModel (Class<T> class)

Casts the current model to the type specified by the class parameter. The specified type must be a child of DocumentModel.

getCroppedDocumentImage

public Bitmap getCroppedDocumentImage ()

Returns a cropped image of the scanned document.

getCroppedDocumentImagePath

public String getCroppedDocumentImagePath ()

Returns the file path of the saved cropped document image.

getOriginalDocumentImage

public Bitmap getDocumentImage ()

Returns an image of the scanned document.

getOriginalDocumentImagePath

public String getDocumentImagePath ()

Returns the file path of the saved document image.

saveImages

public void saveImage (Context context)

Saves all images within the model to the local device and populates all path fields.

Last updated