Object OmidServiceJsRepository
-
- All Implemented Interfaces:
public class OmidServiceJsRepositoryA repository for managing the OMID (Open Measurement Interface Definition) JavaScript.
This object provides methods to fetch and retrieve the OMID JavaScript, either from local storage or from the network. It also manages the fetching status of the OMID script.
-
-
Field Summary
Fields Modifier and Type Field Description public final static OmidServiceJsRepositoryINSTANCE
-
Method Summary
Modifier and Type Method Description final StringgetOmidScript()Retrieves the OMID JavaScript. final UnitfetchOmidScript()Fetches the OMID JavaScript from the network. final Unitclear()-
-
Method Detail
-
getOmidScript
final String getOmidScript()
Retrieves the OMID JavaScript.
This method first attempts to retrieve the OMID JavaScript from the local source. If it's not available locally, it reads the OMID JavaScript from the raw resources.
- Returns:
The OMID JavaScript as a String, or an empty string if the context is null.
-
fetchOmidScript
final Unit fetchOmidScript()
Fetches the OMID JavaScript from the network.
This method checks if the OMID JavaScript should be fetched based on the current status and configuration. If it should be fetched, it attempts to fetch the script from the network and save it locally.
-
-
-
-