Class DefaultScheduleFactory

java.lang.Object
repast.simphony.engine.schedule.DefaultScheduleFactory
All Implemented Interfaces:
IScheduleFactory

public class DefaultScheduleFactory extends Object implements IScheduleFactory
A schedule factory that constructs Schedules.
Version:
$Revision: 1.1 $ $Date: 2005/12/21 22:25:34 $
Author:
Jerry Vos
  • Constructor Details

    • DefaultScheduleFactory

      public DefaultScheduleFactory()
      Synonymous with DefaultScheduleFactory(new DefaultSchedulableActionFactory)
      See Also:
    • DefaultScheduleFactory

      public DefaultScheduleFactory(ISchedulableActionFactory defaultActionFactory)
      Constructs this ScheduleFactory which will default to creating schedules with the specified action factory
      Parameters:
      defaultActionFactory - the default action factory the created schedules will be fed
  • Method Details

    • createSchedule

      public ISchedule createSchedule(ISchedulableActionFactory factory)
      Creates a Schedule that will use the specified ISchedulableActionFactory to create its scheduled actions.
      Specified by:
      createSchedule in interface IScheduleFactory
      Parameters:
      factory - the factory to use to create the actions that the Schedule will schedule
      Returns:
      a schedule that uses the specified factory
    • createSchedule

      public ISchedule createSchedule()
      Creates a Schedule that by default uses the factory set in this interface to create its scheduled actions.

      The behavior that occurs when a default action factory has not been set is per-implementation specific, but in most cases there should be a reasonable default.

      Specified by:
      createSchedule in interface IScheduleFactory
      Returns:
      a schedule that uses the default factory
    • setDefaultSchedulableActionFactory

      public void setDefaultSchedulableActionFactory(ISchedulableActionFactory defaultFactory)
      Sets the action factory that will be used when createSchedule is called with no arguments.
      Specified by:
      setDefaultSchedulableActionFactory in interface IScheduleFactory
      Parameters:
      defaultFactory - the default factory to use if one isn't specified