# -*- coding: utf-8 -*-

"""
coingeckoapiv3

This file was automatically generated by APIMATIC v3.0 (
 https://www.apimatic.io ).
"""

from coingeckoapiv3.decorators import lazy_property
from coingeckoapiv3.configuration import Configuration
from coingeckoapiv3.configuration import Environment
from coingeckoapiv3.controllers.ping_controller import PingController
from coingeckoapiv3.controllers.simple_controller import SimpleController
from coingeckoapiv3.controllers.coins_controller import CoinsController
from coingeckoapiv3.controllers.contract_controller import ContractController
from coingeckoapiv3.controllers.asset_platforms_controller\
    import AssetPlatformsController
from coingeckoapiv3.controllers.categories_controller\
    import CategoriesController
from coingeckoapiv3.controllers.exchanges_controller import ExchangesController
from coingeckoapiv3.controllers.finance_controller import FinanceController
from coingeckoapiv3.controllers.indexes_controller import IndexesController
from coingeckoapiv3.controllers.derivatives_controller\
    import DerivativesController
from coingeckoapiv3.controllers.status_updates_controller\
    import StatusUpdatesController
from coingeckoapiv3.controllers.events_controller import EventsController
from coingeckoapiv3.controllers.exchange_rates_controller\
    import ExchangeRatesController
from coingeckoapiv3.controllers.trending_controller import TrendingController
from coingeckoapiv3.controllers.global_controller import GlobalController
from coingeckoapiv3.controllers.companies_beta_controller\
    import CompaniesBetaController


class Coingeckoapiv3Client(object):

    @lazy_property
    def ping(self):
        return PingController(self.config)

    @lazy_property
    def simple(self):
        return SimpleController(self.config)

    @lazy_property
    def coins(self):
        return CoinsController(self.config)

    @lazy_property
    def contract(self):
        return ContractController(self.config)

    @lazy_property
    def asset_platforms(self):
        return AssetPlatformsController(self.config)

    @lazy_property
    def categories(self):
        return CategoriesController(self.config)

    @lazy_property
    def exchanges(self):
        return ExchangesController(self.config)

    @lazy_property
    def finance(self):
        return FinanceController(self.config)

    @lazy_property
    def indexes(self):
        return IndexesController(self.config)

    @lazy_property
    def derivatives(self):
        return DerivativesController(self.config)

    @lazy_property
    def status_updates(self):
        return StatusUpdatesController(self.config)

    @lazy_property
    def events(self):
        return EventsController(self.config)

    @lazy_property
    def exchange_rates(self):
        return ExchangeRatesController(self.config)

    @lazy_property
    def trending(self):
        return TrendingController(self.config)

    @lazy_property
    def mglobal(self):
        return GlobalController(self.config)

    @lazy_property
    def companies_beta(self):
        return CompaniesBetaController(self.config)

    def __init__(self, timeout=60, max_retries=0, backoff_factor=2,
                 retry_statuses=[408, 413, 429, 500, 502, 503, 504, 521, 522, 524],
                 retry_methods=['GET', 'PUT'],
                 environment=Environment.PRODUCTION, config=None):
        if config is None:
            self.config = Configuration(timeout=timeout,
                                        max_retries=max_retries,
                                        backoff_factor=backoff_factor,
                                        retry_statuses=retry_statuses,
                                        retry_methods=retry_methods,
                                        environment=environment)
        else:
            self.config = config
