public class PageFactory
extends java.lang.Object
Pages and saves their content in file systemPageStoreStrategy| Modifier and Type | Class and Description |
|---|---|
static class |
PageFactory.Result
Result of
Page creation. |
| Constructor and Description |
|---|
PageFactory(BitmapLruCache bitmapLruCache,
PageStoreStrategy pageStoreStrategy) |
| Modifier and Type | Method and Description |
|---|---|
Page |
buildPage(android.graphics.Bitmap image)
Builds new
Page from provided data. |
PageFactory.Result |
buildPage(android.graphics.Bitmap image,
int screenWidth,
int screenHeight)
Builds new
Page from provided data. |
Page |
buildPage(byte[] image)
Builds new
Page from provided data. |
PageFactory.Result |
buildPage(byte[] image,
int screenWidth,
int screenHeight)
Builds new
Page from provided data. |
Page |
buildPage(java.io.File image)
Builds new
Page from provided data. |
public PageFactory(BitmapLruCache bitmapLruCache,
PageStoreStrategy pageStoreStrategy)
public final PageFactory.Result buildPage(android.graphics.Bitmap image, int screenWidth, int screenHeight) throws java.io.IOException
Page from provided data. Result represented as
PageFactory.Result class.
Might perform image compression, so if you're already have compressed image (in a file system, for instance)
consider using buildPage(byte[], int, int) instead
java.io.IOExceptionpublic PageFactory.Result buildPage(byte[] image, int screenWidth, int screenHeight) throws java.io.IOException
Page from provided data. Result represented as
PageFactory.Result class.image - original image bytesscreenWidth - width of the device screenscreenHeight - height of the device screenPageFactory.Result which contains information about
the created Pagejava.io.IOException - in case if files associated with Page could
not be created.public final Page buildPage(android.graphics.Bitmap image) throws java.io.IOException
Page from provided data.java.io.IOException - in case if files associated with Page could
not be created.public Page buildPage(byte[] image) throws java.io.IOException
Page from provided data.