Esempio n. 1
0
        // Gets the singleton client for the specified network.
        private static IAdClient CreateAdClient(AdNetwork network)
        {
            var settings = EM_Settings.Advertising;

            switch (network)
            {
            case AdNetwork.AdColony:
                return(AdColonyClientImpl.CreateClient(settings));

            case AdNetwork.AdMob:
                return(AdMobClientImpl.CreateClient(settings));

            case AdNetwork.Chartboost:
                return(ChartboostClientImpl.CreateClient(settings));

            case AdNetwork.Heyzap:
                return(HeyzapClientImpl.CreateClient(settings));

            case AdNetwork.UnityAds:
                return(UnityAdsClientImpl.CreateClient(settings));

            case AdNetwork.None:
                return(NoOpClientImpl.CreateClient());

            default:
                throw new NotImplementedException("No client implemented for the network:" + network.ToString());
            }
        }