code: def get_rank_value(cls, name):
      
      if name in cls._RANK_NAMES.values():
        return getattr(cls, name, None)
      return None
docs: Returns the integer constant value for the given rank name.
  
      :param string rank: the string rank name (E.g., 'HARDCODED').
      :returns: the integer constant value of the rank.
      :rtype: int