def __init__(self, url_load_hook=None, default_getter=None):
        """
        args:
         - url_load_hook: a way to redirect url to a accessible place, for self testing
         - default_getter: the default getter used when none is provided in 'resolve' method
        """
        # a map from url to loaded json/yaml
        self.__cache = {}

        # things to make unittest easier,
        # all urls to load json would go through this hook
        self.__url_load_hook = url_load_hook

        # default getter for all resolving
        self.__default_getter = default_getter
def __init__ ( self , url_load_hook = None , default_getter = None ) : self . __cache = { } self . __url_load_hook = url_load_hook self . __default_getter = default_getter
args:
         - url_load_hook: a way to redirect url to a accessible place, for self testing
         - default_getter: the default getter used when none is provided in 'resolve' method