Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Native
Skip to main content

Interface IProgramLineupProvider

interface IProgramLineupProvider
Extends com.amazon.apmf.IStandard Interface representing the data provider object used for adding programs to or clearing programs from the EPG. This interface is deprecated, please use IProgramLineupProvider2 instead. This provider is used to update the program lineup in the EPG. The upsert() function can be called multiple times within the same provider object to add programs to the commit queue. All operations performed within the provider will be persisted when the commit() function is called. If the provider object is destroyed before calling commit(), all changes that were queued up will be lost. Please note that this interface is not thread-safe. Do not create multiple instances of this object for use in different threads to avoid non-deterministic behavior. Please discard this object and create a new instance if this object has thrown an error in one of its methods.

Methods

upsert()

void upsert(com.amazon.kepler.tv.epg_provider_models.IProgram*[] programs)
Upserts a list of programs for the program lineup in the EPG. Inserts programs into the LiveTV Provider data store. This action is not persisted until commit() is called.

Parameters

programs
com.amazon.kepler.tv.epg_provider_models.IProgram*[] — Required An array of program instances to be inserted.

Throws

  • IllegalStateError — if this function is called after the same ProgramLineupProvider has already thrown an error previously in one of its methods.
  • InternalError — if this function encounters an unrecoverable error such as data store connection issues, etc.
  • StorageLimitError — if this function encounters an error due to ingested data exceeding the storage limit. Consult with your Amazon contact if you encounter this error.

clearAllPrograms()

void clearAllPrograms()
Clears all programs from the data store. Removes all programs from the data store. This action is not persisted until commit() is called. This will not clear channel information from the data store. Utilize this function exclusively when there is a need to remove added programs from the Electronic Program Guide (EPG). The function call for clearAllPrograms() must preceed all calls to upsert() within the same transaction.

Throws

  • IllegalStateError — if clearAllPrograms() is called after upsert() has already been called within this transaction, or if this function is called after the same ProgramLineupProvider has already thrown an InternalError previously.
  • InternalError — if the program data cannot be cleared for any other reason.

commit()

void commit(string version)
Commits any pending operations from this provider object to the data store. This function should be called after performing operations on the provider using the other methods in the provider interface. EpgLineupInformation.getLastCommittedProgramLineupVersion() will begin to return this version value once this call succeeds.

Parameters

version
string — Required A string representing the version of the program lineup that will be in the data store as a result of this commit. Please refer to the developer guide for more information on how to use this field.

Throws

  • IllegalStateError — if this function is called after the same ProgramLineupProvider has already thrown an InternalError previously in one of its methods.
  • InternalError — if the data cannot be committed to the LiveTV Providers data store.

Last modified on October 29, 2026