class TZInfo::DataSources::ZoneinfoDataSource
def resolve_tab_path(zoneinfo_path, standard_names, tab_name)
-
(String)
- the path to the tab file.
Parameters:
-
tab_name
(String
) -- the alternate name for the tab file to check in -
standard_names
(Array
) -- the standard names for the tab -
zoneinfo_path
(String
) -- the path to a zoneinfo directory.
def resolve_tab_path(zoneinfo_path, standard_names, tab_name) standard_names.each do |standard_name| path = File.join(zoneinfo_path, standard_name) return path if File.file?(path) end path = File.join(zoneinfo_path, 'tab', tab_name) return path if File.file?(path) nil end