Package xyz.ressor

Class PollingBuilder


  • public class PollingBuilder
    extends java.lang.Object
    This class is responsible for building polling-based service loaders.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void cron​(java.lang.String expression)
      Poll the Source for the new version of data, if available, by Cron schedule.
      void every​(int timeValue, java.util.concurrent.TimeUnit unit)
      Poll the Source for the new version of data, if available, for every timeValue.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • every

        public void every​(int timeValue,
                          java.util.concurrent.TimeUnit unit)
        Poll the Source for the new version of data, if available, for every timeValue.
        Parameters:
        timeValue - the time amount between polling
        unit - the unit of time
      • cron

        public void cron​(java.lang.String expression)
        Poll the Source for the new version of data, if available, by Cron schedule. http://www.quartz-scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html See https://www.freeformatter.com/cron-expression-generator-quartz.html for handy expression building.
        Parameters:
        expression - the cron expression