Class GtfsBundle


  • public class GtfsBundle
    extends Object
    Captures the path to a gtfs feed, along with information about a default agency id for the feed and agency id translation information. The bundle can optionally specify a URL to a feed to be downloaded, but the file path will take precedence if specified.
    Author:
    bdferris
    See Also:
    GtfsBundles, FederatedTransitDataBundleCreator
    • Constructor Detail

      • GtfsBundle

        public GtfsBundle()
    • Method Detail

      • getPath

        public File getPath()
        Returns:
        the path to the feed (either a directory or zip file)
      • setPath

        public void setPath​(File path)
        Parameters:
        path - the path to the feed (either a directory or a zip file)
      • getUrl

        public URL getUrl()
        Returns:
        a url where the feed can be downloaded, though getPath() will take precedence)
      • setUrl

        public void setUrl​(URL url)
        Parameters:
        url - a url where the feed can be downloaded, though setPath(File) will take precedence)
      • getDefaultAgencyId

        public String getDefaultAgencyId()
        Returns:
        the default agency id for the feed (see GtfsReader#setDefaultAgencyId(String))
      • setDefaultAgencyId

        public void setDefaultAgencyId​(String defaultAgencyId)
        Parameters:
        defaultAgencyId - the default agency id for the feed (see GtfsReader#setDefaultAgencyId(String))
      • getAgencyIdMappings

        public Map<String,​String> getAgencyIdMappings()
        Returns:
        a set of agency id mappings that will be used to replace any matching agency i
      • setAgencyIdMappings

        public void setAgencyIdMappings​(Map<String,​String> agencyIdMappings)
        Parameters:
        agencyIdMappings - a set of agency id mappings that will be used to replace any matching agency ids in the feed