Class FederatedTransitDataBundleCreator
- java.lang.Object
-
- org.onebusaway.transit_data_federation.bundle.FederatedTransitDataBundleCreator
-
public class FederatedTransitDataBundleCreator extends Object
The primary method for building a new federated transit data bundle, which is the collection of resources and optimized data structures necessary to power a federated transit data bundle instance. The bundle is constructed from a number of input resources, includingGtfsBundleobjects and street network resources. While this class can be accessed directly, it is mostly designed to be run from the command line using theFederatedTransitDataBundleCreatorMainrunner. Various stages of the bundle building process can be conditionally enabled and disabled by passingStagesarguments to methods like#setStageToSkip(Stages). All stages are enabled by default. The build process is configured using Spring and additional context config paths can be specified to add to the Spring container (seesetContextPaths(List)). The core config is kept in the resource: "classpath:org/onebusaway/transit_data_federation/bundle/application-context-bundle-creator.xml"- Author:
- bdferris
- See Also:
FederatedTransitDataBundleCreatorMain
-
-
Constructor Summary
Constructors Constructor Description FederatedTransitDataBundleCreator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddTaskToInclude(String taskToInclude)voidaddTaskToOnlyRun(String onlyTask)voidaddTaskToSkip(String taskToSkip)StatusMessagesgetStatusMessages()voidrun()Build the bundle!voidsetAdditionalBeanPropertyOverrides(Properties props)voidsetBundleKey(String key)voidsetContext(org.springframework.context.ConfigurableApplicationContext context)voidsetContextBeans(Map<String,org.springframework.beans.factory.config.BeanDefinition> contextBeans)voidsetContextPaths(List<String> paths)Additional context paths that will be added when constructing the Spring container that controls the build process.voidsetOutputPath(File outputPath)voidsetRandomizeCacheDir(boolean randomizeCacheDir)voidsetSkipToTask(String taskName)
-
-
-
Method Detail
-
setContext
@Autowired public void setContext(org.springframework.context.ConfigurableApplicationContext context)
- Parameters:
context-
-
setContextPaths
public void setContextPaths(List<String> paths)
Additional context paths that will be added when constructing the Spring container that controls the build process. SeeContainerLibrary.createContext(Iterable).- Parameters:
contextPaths- additional Spring context paths to add to the container
-
setContextBeans
public void setContextBeans(Map<String,org.springframework.beans.factory.config.BeanDefinition> contextBeans)
-
setOutputPath
public void setOutputPath(File outputPath)
- Parameters:
outputPath- the output path of the bundle
-
setBundleKey
public void setBundleKey(String key)
-
addTaskToOnlyRun
public void addTaskToOnlyRun(String onlyTask)
-
addTaskToSkip
public void addTaskToSkip(String taskToSkip)
-
addTaskToInclude
public void addTaskToInclude(String taskToInclude)
-
setSkipToTask
public void setSkipToTask(String taskName)
-
setRandomizeCacheDir
public void setRandomizeCacheDir(boolean randomizeCacheDir)
-
setAdditionalBeanPropertyOverrides
public void setAdditionalBeanPropertyOverrides(Properties props)
-
getStatusMessages
public StatusMessages getStatusMessages()
-
run
public void run() throws IOException, ClassNotFoundException, UnknownTaskExceptionBuild the bundle!
-
-