Class CalendarConfigurationBuilder

java.lang.Object
com.caplin.motif.fx.ret.calendar.config.CalendarConfigurationBuilder

public class CalendarConfigurationBuilder extends Object
This class produces a CalendarConfiguration which can be used to instantiate a CalendarAdapter.
  • Field Details

  • Constructor Details

  • Method Details

    • setDataTransformer

      public CalendarConfigurationBuilder setDataTransformer(CalendarDataTransformer dataTransformer)
      Sets a custom CalendarDataTransformer to extend the CalendarAdapter's default behaviour.
      Parameters:
      dataTransformer - a custom CalendarDataTransformer
      Returns:
      the CalendarConfigurationBuilder
    • setAdapterConfigurationListener

      public CalendarConfigurationBuilder setAdapterConfigurationListener(AdapterConfigurationListener listener)
      Sets a custom AdapterConfigurationListener to load custom configurations.
      Parameters:
      listener - The listener that will receive a callback to load custom configurations
      Returns:
      the CalendarConfigurationBuilder
    • setDataSource

      public CalendarConfigurationBuilder setDataSource(com.caplin.datasource.DataSource dataSource)
      Sets a custom DataSource to extend the CalendarAdapter's default behaviour.
      Parameters:
      dataSource - a custom DataSource
      Returns:
      the CalendarConfigurationBuilder
    • setConfigurationLoader

      public CalendarConfigurationBuilder setConfigurationLoader(ConfigurationLoader configurationLoader)
      Sets a custom ConfigurationLoader to replace the CalendarAdapter's default behaviour.
      Parameters:
      configurationLoader - a custom ConfigurationLoader
      Returns:
      the CalendarConfigurationBuilder
    • setInstrumentProvider

      public CalendarConfigurationBuilder setInstrumentProvider(InstrumentProvider instrumentProvider)
      Sets a custom InstrumentProvider to replace the CalendarAdapter's default behaviour.
      Parameters:
      instrumentProvider - a custom InstrumentProvider
      Returns:
      the CalendarConfigurationBuilder
    • setUserManager

      public CalendarConfigurationBuilder setUserManager(UserManager userManager)
      Sets a custom UserManager to replace the CalendarAdapter's default behaviour.
      Parameters:
      userManager - a custom UserManager
      Returns:
      the CalendarConfigurationBuilder
    • setSettlementSubjectParser

      public CalendarConfigurationBuilder setSettlementSubjectParser(com.caplin.motif.datasource.SubjectParser<com.caplin.motif.fx.ret.calendar.subject.RETSettlementDateSubjectInfo> settlementSubjectParser)
    • setTenorSubjectParser

      public CalendarConfigurationBuilder setTenorSubjectParser(com.caplin.motif.datasource.SubjectParser<com.caplin.motif.fx.ret.calendar.subject.RETTenorDateSubjectInfo> tenorSubjectParser)
    • build

      public CalendarConfiguration build()
      Creates an instance of CalendarConfiguration which can be used to instantiate a CalendarAdapter.
      Returns:
      a new CalendarConfiguration