Package com.microblink.blinkid.entities.util

# Class IntentTransferableEntity<E extends Entity>

java.lang.Object
com.microblink.blinkid.intent.BaseIntentTransferable<IntentTransferableEntity<E>>
com.microblink.blinkid.entities.util.IntentTransferableEntity<E>

Type Parameters:
  `E` - concrete type of the `Entity` that needs to be transferred over intent

All Implemented Interfaces:
  `android.os.Parcelable`, `com.microblink.blinkid.intent.MBIntentTransferable`

public abstract class IntentTransferableEntity<E extends Entity> extends com.microblink.blinkid.intent.BaseIntentTransferable<IntentTransferableEntity<E>>
Helper class whose concrete implementations can be used for transferring single entity over intent. Entity objects can be large and this class enables transferring them over intent, because there is a limitation on maximum allowed size of Android intent extras.

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from interface android.os.Parcelable

  `android.os.Parcelable.ClassLoaderCreator<T extends Object>, android.os.Parcelable.Creator<T extends Object>`

- ## Field Summary

  ### Fields inherited from interface android.os.Parcelable

  `CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE`

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `IntentTransferableEntity()`
  `protected`
  `IntentTransferableEntity(android.os.Parcel in)`
  ``
  `IntentTransferableEntity(E entity)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected void`
  `consumeContentFromLoadedObject(IntentTransferableEntity<E> loadedObject)`
  Consumes content from object loaded from intent.
  `protected E`
  `getEntity()`
  `protected void`
  `readFromParcel(android.os.Parcel in)`
  `void`
  `saveToIntent(android.content.Intent intent)`
  Saves this `BaseIntentTransferable` to `Intent` so it can be passed to another `Activity`.
  `void`
  `writeToParcel(android.os.Parcel dest, int flags)`

  ### Methods inherited from class com.microblink.blinkid.intent.BaseIntentTransferable

  `clearSavedState, describeContents, existsInIntent, getConcreteCreator, getUniqueIdIntentExtraKey, loadFromIntent, saveState`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### IntentTransferableEntity

    public IntentTransferableEntity(@NonNull E entity)

  - ### IntentTransferableEntity

    protected IntentTransferableEntity()

  - ### IntentTransferableEntity

    protected IntentTransferableEntity(@NonNull android.os.Parcel in)

- ## Method Details

  - ### getEntity

    @NonNull protected E getEntity()

  - ### consumeContentFromLoadedObject

    protected void consumeContentFromLoadedObject(@NonNull IntentTransferableEntity<E> loadedObject)
    Description copied from class: `com.microblink.blinkid.intent.BaseIntentTransferable`
    Consumes content from object loaded from intent.
    Specified by:
      `consumeContentFromLoadedObject` in class `com.microblink.blinkid.intent.BaseIntentTransferable<IntentTransferableEntity<E extends Entity>>`

  - ### saveToIntent

    public void saveToIntent(@NonNull android.content.Intent intent)
    Description copied from class: `com.microblink.blinkid.intent.BaseIntentTransferable`
    Saves this `BaseIntentTransferable` to `Intent` so it can be passed to another `Activity`.
    Specified by:
      `saveToIntent` in interface `com.microblink.blinkid.intent.MBIntentTransferable`
    Overrides:
      `saveToIntent` in class `com.microblink.blinkid.intent.BaseIntentTransferable<IntentTransferableEntity<E extends Entity>>`
    Parameters:
      `intent` - Intent to which `BaseIntentTransferable` should be saved.

  - ### readFromParcel

    protected void readFromParcel(@NonNull android.os.Parcel in)
    Overrides:
      `readFromParcel` in class `com.microblink.blinkid.intent.BaseIntentTransferable<IntentTransferableEntity<E extends Entity>>`

  - ### writeToParcel

    public void writeToParcel(@NonNull android.os.Parcel dest, int flags)
    Specified by:
      `writeToParcel` in interface `android.os.Parcelable`
    Overrides:
      `writeToParcel` in class `com.microblink.blinkid.intent.BaseIntentTransferable<IntentTransferableEntity<E extends Entity>>`