class_docstr: A class for dispatching and caching trading calendars.
  
  Methods of a global instance of this class are provided by
  catalyst.utils.calendar_utils.
  
  Parameters
  ----------
  calendars : dict[str -> TradingCalendar]
      Initial set of calendars.
  calendar_factories : dict[str -> function]
      Factories for lazy calendar creation.
  aliases : dict[str -> str]
      Calendar name aliases.
class_docstr_tok: ["A","class","for","dispatching","and","caching","trading","calendars",".","Methods","of","a","global","instance","of","this","class","are","provided","by","catalyst.utils.calendar_utils",".","Parameters","--","--","--","--","--","calendars",":","dict","[","str","-",">","TradingCalendar","]","Initial","set","of","calendars",".","calendar_factories",":","dict","[","str","-",">","function","]","Factories","for","lazy","calendar","creation",".","aliases",":","dict","[","str","-",">","str","]","Calendar","name","aliases","."]
docstr: Resolve a calendar alias for retrieval.
  
  Parameters
  ----------
  name : str
      The name of the requested calendar.
  
  Returns
  -------
  canonical_name : str
      The real name of the calendar to create/return.
docstr_tok: ["Resolve","a","calendar","alias","for","retrieval",".","Parameters","--","--","--","--","--","name",":","str","The","name","of","the","requested","calendar",".","Returns","--","--","--","-","canonical_name",":","str","The","real","name","of","the","calendar","to","create\/return","."]
code: def resolve_alias(self, name):
      """
      Resolve a calendar alias for retrieval.
  
      Parameters
      ----------
      name : str
          The name of the requested calendar.
  
      Returns
      -------
      canonical_name : str
          The real name of the calendar to create/return.
      """
      # Use an OrderedDict as an ordered set so that we can return the order
      # of aliases in the event of a cycle.
      seen = []
  
      while name in self._aliases:
          seen.append(name)
          name = self._aliases[name]
  
          # This is O(N ** 2), but if there's an alias chain longer than 2,
          # something strange has happened.
          if name in seen:
              seen.append(name)
              raise CyclicCalendarAlias(
                  cycle=" -> ".join(repr(k) for k in seen)
              )
  
      return name
  
imports: from catalyst.errors import CalendarNameCollision, CyclicCalendarAlias, InvalidCalendarName
  from .exchange_calendar_open import OpenExchangeCalendar
  from .exchange_calendar_cfe import CFEExchangeCalendar
  from .exchange_calendar_ice import ICEExchangeCalendar
  from .exchange_calendar_nyse import NYSEExchangeCalendar
  from .exchange_calendar_cme import CMEExchangeCalendar
  from .exchange_calendar_bmf import BMFExchangeCalendar
  from .exchange_calendar_lse import LSEExchangeCalendar
  from .exchange_calendar_tsx import TSXExchangeCalendar
  from .us_futures_calendar import QuantopianUSFuturesCalendar
label_desc: Use image node_id 7 for calling the TradingCalendarDispatcher obj's underlying member method code with example usage: obj.resolve_alias(name) and returns: name