Interface DataRoutingService.PropertyProvider

All Known Subinterfaces:
DataRoutingService.DataImportServiceConfig, DataRoutingService.LogAggregatorConfig, DataRoutingService.TableDataServiceConfig
All Known Implementing Classes:
DataRoutingService.DataImportServiceConfig.Delegating, DataRoutingService.NullPropertyProvider
Enclosing interface:
DataRoutingService

public static interface DataRoutingService.PropertyProvider
Provides access to "other" configuration properties for several interfaces.
  • Method Summary

    Modifier and Type Method Description
    Map<Object,​Object> asMap()
    Return all properties as a map.
    Object getProperty​(String propertyName)
    Return the named property value, or null.
    <T> T getProperty​(String propertyName, T defaultValue)
    Return the named property value, with the type indicated by the default value.
  • Method Details

    • getProperty

      @Nullable Object getProperty​(@NotNull String propertyName)
      Return the named property value, or null. The actual type is determined by the implementation.
      Parameters:
      propertyName - the name of the property to fetch
      Returns:
      the value of the property, or null if not set
    • getProperty

      @NotNull <T> T getProperty​(@NotNull String propertyName, @NotNull T defaultValue)
      Return the named property value, with the type indicated by the default value. If the property isn't set, return the default value.
      Parameters:
      propertyName - the name of the property to fetch
      defaultValue - the typed default value to return if the property is not set
      Returns:
      the value of the property, or null if not set
      Throws:
      DataRoutingConfigurationException - if the actual value cannot be returned as the defaultValue type
    • asMap

      @NotNull Map<Object,​Object> asMap()
      Return all properties as a map. This is useful for interactions outside the DB project.
      Returns:
      a map containing all keys and values for this provider