public class SportEventCacheImpl extends Object implements SportEventCache, DataRouterListener, ExportableSdkCache
| Modifier and Type | Method and Description |
|---|---|
void |
addFixtureTimestamp(Urn id)
Adds fixture timestamp to cache so that the next fixture calls for the event goes trough non-cached fixture provider
|
Map<String,Long> |
cacheStatus()
Returns current cache status
|
Integer |
deleteSportEventsFromCache(Date before)
Deletes the sport events from cache which are scheduled before specified date
|
List<ExportableCi> |
exportItems()
Exports current items in the cache
|
SportEventCi |
getEventCacheItem(Urn id)
Returns a
SportEventCi instance representing a cached sport event data |
SportEventCi |
getEventCacheItem(Urn id,
RequestOptions requestOptions)
Returns a
SportEventCi instance representing a cached sport event data |
List<Urn> |
getEventIds(Date date,
Locale locale)
|
List<Urn> |
getEventIds(Urn tournamentId,
Locale locale)
Returns a
List containing id's of sport events, which belong to a specific tournament |
void |
importItems(List<ExportableCi> items)
Imports provided items into the cache
|
void |
onChildSportEventFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiSportEventChildren.SapiSportEvent data,
Locale dataLocale) |
void |
onDrawFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiDrawEvent data,
Locale dataLocale,
CacheItem requester) |
void |
onDrawFixtureFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiDrawFixture data,
Locale dataLocale,
CacheItem requester) |
void |
onDrawSummaryEndpointFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiDrawSummary data,
Locale dataLocale,
CacheItem requester) |
void |
onEventBooked(Urn id)
Method that gets triggered when the associated event gets booked trough the
BookingManager |
void |
onFixtureFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiFixture data,
Locale dataLocale,
CacheItem requester) |
void |
onLotteryFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiLottery data,
Locale dataLocale,
CacheItem requester) |
void |
onMatchSummaryEndpointFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiMatchSummaryEndpoint data,
Locale dataLocale,
CacheItem requester) |
void |
onMatchTimelineFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiMatchTimelineEndpoint data,
Locale dataLocale,
CacheItem requester) |
void |
onSportEventFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiSportEvent data,
Locale dataLocale) |
void |
onStageSummaryEndpointFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiStageSummaryEndpoint data,
Locale dataLocale,
CacheItem requester) |
void |
onTournamentExtendedFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiTournamentExtended data,
Locale dataLocale) |
void |
onTournamentFetched(Urn id,
com.sportradar.uf.sportsapi.datamodel.SapiTournament data,
Locale locale) |
void |
onTournamentInfoEndpointFetched(Urn requestedId,
Urn tournamentId,
Urn seasonId,
com.sportradar.uf.sportsapi.datamodel.SapiTournamentInfoEndpoint data,
Locale dataLocale,
CacheItem requester) |
void |
purgeCacheItem(Urn id)
Purges an item from the
SportEventCache |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitonAvailableSelectionsFetched, onCalculateProbabilityFetched, onCalculateProbabilityFilterFetched, onCompetitorFetched, onPlayerFetched, onSimpleTeamFetched, onSportCategoriesFetched, onSportEventStatusFetched, onSportFetched, onSportTournamentsFetched, onTeamFetchedpublic SportEventCi getEventCacheItem(Urn id) throws CacheItemNotFoundException
SportEventCi instance representing a cached sport event datagetEventCacheItem in interface SportEventCacheid - an Urn specifying the id of the sport eventSportEventCi instance representing cached sport event dataCacheItemNotFoundExceptionpublic SportEventCi getEventCacheItem(Urn id, RequestOptions requestOptions) throws CacheItemNotFoundException
SportEventCi instance representing a cached sport event datagetEventCacheItem in interface SportEventCacheid - an Urn specifying the id of the sport eventrequestOptions - a RequestOptions object with the configuration of request issued to DataRouterManagerSportEventCi instance representing cached sport event dataCacheItemNotFoundExceptionpublic List<Urn> getEventIds(Urn tournamentId, Locale locale) throws IllegalCacheStateException
List containing id's of sport events, which belong to a specific tournamentgetEventIds in interface SportEventCachetournamentId - an Urn specifying the id of the tournament to which the events should relatelocale - the locale to fetch the dataList containing id's of sport events, which belong to the specified tournamentIllegalCacheStateExceptionpublic List<Urn> getEventIds(Date date, Locale locale) throws IllegalCacheStateException
List containing id's of sport events, which are scheduled for a specific date - if provided;
otherwise a List of currently live events is returnedgetEventIds in interface SportEventCachedate - an optional Date for which the data is providedlocale - the locale to fetch the dataList of events that are happening on the specified Date;
or a List of currently live eventsIllegalCacheStateExceptionpublic void purgeCacheItem(Urn id)
SportEventCachepurgeCacheItem in interface SportEventCacheid - The Urn specifying the event which should be purgedpublic void onSportEventFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiSportEvent data, Locale dataLocale)
onSportEventFetched in interface DataRouterListenerpublic void onChildSportEventFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiSportEventChildren.SapiSportEvent data, Locale dataLocale)
onChildSportEventFetched in interface DataRouterListenerpublic void onTournamentExtendedFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiTournamentExtended data, Locale dataLocale)
onTournamentExtendedFetched in interface DataRouterListenerpublic void onTournamentInfoEndpointFetched(Urn requestedId, Urn tournamentId, Urn seasonId, com.sportradar.uf.sportsapi.datamodel.SapiTournamentInfoEndpoint data, Locale dataLocale, CacheItem requester)
onTournamentInfoEndpointFetched in interface DataRouterListenerpublic void onStageSummaryEndpointFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiStageSummaryEndpoint data, Locale dataLocale, CacheItem requester)
onStageSummaryEndpointFetched in interface DataRouterListenerpublic void onMatchSummaryEndpointFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiMatchSummaryEndpoint data, Locale dataLocale, CacheItem requester)
onMatchSummaryEndpointFetched in interface DataRouterListenerpublic void onFixtureFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiFixture data, Locale dataLocale, CacheItem requester)
onFixtureFetched in interface DataRouterListenerpublic void onTournamentFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiTournament data, Locale locale)
onTournamentFetched in interface DataRouterListenerpublic void onMatchTimelineFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiMatchTimelineEndpoint data, Locale dataLocale, CacheItem requester)
onMatchTimelineFetched in interface DataRouterListenerpublic void onLotteryFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiLottery data, Locale dataLocale, CacheItem requester)
onLotteryFetched in interface DataRouterListenerpublic void onDrawFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiDrawEvent data, Locale dataLocale, CacheItem requester)
onDrawFetched in interface DataRouterListenerpublic void onDrawFixtureFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiDrawFixture data, Locale dataLocale, CacheItem requester)
onDrawFixtureFetched in interface DataRouterListenerpublic void onDrawSummaryEndpointFetched(Urn id, com.sportradar.uf.sportsapi.datamodel.SapiDrawSummary data, Locale dataLocale, CacheItem requester)
onDrawSummaryEndpointFetched in interface DataRouterListenerpublic void onEventBooked(Urn id)
BookingManageronEventBooked in interface SportEventCacheid - the Urn of the event that was successfully bookedpublic void addFixtureTimestamp(Urn id)
addFixtureTimestamp in interface SportEventCacheid - the Urn of the eventpublic Integer deleteSportEventsFromCache(Date before)
deleteSportEventsFromCache in interface SportEventCachebefore - the scheduled Date used to delete sport events from cachepublic List<ExportableCi> exportItems()
exportItems in interface ExportableSdkCacheExportableCi containing all the items currently in the cachepublic void importItems(List<ExportableCi> items)
importItems in interface ExportableSdkCacheitems - List of ExportableCi to be inserted into the cachepublic Map<String,Long> cacheStatus()
cacheStatus in interface ExportableSdkCacheCopyright © 2016–2025. All rights reserved.