Class FeedMessageHelper
java.lang.Object
com.sportradar.unifiedodds.sdk.internal.impl.util.FeedMessageHelper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgenerateFixtureChangeCacheKey(com.sportradar.uf.datamodel.UfFixtureChange fixtureChange) Returns a built cache key for the providedUfFixtureChangestatic StringProvides the id of the associated event if available, otherwise an explanation why the eventId is not available get(ex: for a snapshot complete -> system message)static longProvides the message timestampstatic LongProvides the message generation timestamp, the generation timestamp is extracted only from the betstop and oddschange messagestatic intProvides the id of the message producerstatic LongProvides the request id of the message (if present)
-
Constructor Details
-
FeedMessageHelper
public FeedMessageHelper()
-
-
Method Details
-
provideProducerIdFromMessage
Provides the id of the message producer- Parameters:
o- - the message from which the producerId should be provided- Returns:
- - the id of the message producer
-
generateFixtureChangeCacheKey
public static String generateFixtureChangeCacheKey(com.sportradar.uf.datamodel.UfFixtureChange fixtureChange) Returns a built cache key for the providedUfFixtureChange- Parameters:
fixtureChange- the object for which the key is needed- Returns:
- a built cache key for the provided
UfFixtureChange
-
provideEventIdFromMessage
Provides the id of the associated event if available, otherwise an explanation why the eventId is not available get(ex: for a snapshot complete -> system message)- Parameters:
o- - the message from which the eventIdd should be provided- Returns:
- - the associated eventId or an explanation why the eventId is not available (ex: for a snapshot complete -> system message)
-
provideMessageGenTimestampFromMessage
Provides the message generation timestamp, the generation timestamp is extracted only from the betstop and oddschange message- Parameters:
o- the message from which the timestamp should be provided- Returns:
- the message generation timestamp if available; otherwise null
-
provideGenTimestampFromMessage
Provides the message timestamp- Parameters:
o- the message from which the timestamp should be provided- Returns:
- the message timestamp
-
provideRequestIdFromMessage
Provides the request id of the message (if present)- Parameters:
o- - the message from which the requestId should be provided- Returns:
- - the id of the recovery request associated with the message
-