Examples of ISchedulingService


Examples of org.red5.server.api.scheduling.ISchedulingService

   *            Scheduled job object
   *
   * @return Name of the scheduled job
   */
  public String addScheduledJob(int interval, IScheduledJob job) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    return service.addScheduledJob(interval, job);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   *            Scheduled job object
   *
   * @return Name of the scheduled job
   */
  public String addScheduledOnceJob(long timeDelta, IScheduledJob job) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    return service.addScheduledOnceJob(timeDelta, job);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   *            Scheduled job object
   *
   * @return Name of the scheduled job
   */
  public String addScheduledOnceJob(Date date, IScheduledJob job) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    return service.addScheduledOnceJob(date, job);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   * @param delay
   *            time in milliseconds to pass before first execution.
   * @return the name of the scheduled job
   */
  public String addScheduledJobAfterDelay(int interval, IScheduledJob job, int delay) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    return service.addScheduledJobAfterDelay(interval, job, delay);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   *
   * @param name
   *            Scheduled job name
   */
  public void pauseScheduledJob(String name) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    service.pauseScheduledJob(name);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   *
   * @param name
   *            Scheduled job name
   */
  public void resumeScheduledJob(String name) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    service.resumeScheduledJob(name);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   *
   * @param name
   *            Scheduled job name
   */
  public void removeScheduledJob(String name) {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    service.removeScheduledJob(name);
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

   * Returns list of scheduled job names
   *
   * @return List of scheduled job names as list of Strings.
   */
  public List<String> getScheduledJobNames() {
    ISchedulingService service = (ISchedulingService) ScopeUtils.getScopeService(scope, ISchedulingService.class, QuartzSchedulingService.class, false);
    return service.getScheduledJobNames();
  }
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

      Scope scope = new DummyScope();
      scope.setName("");
      scope.setContext(ctx);
      pss.setScope(scope);
      //
      ISchedulingService schedulingService = (ISchedulingService) applicationContext.getBean(ISchedulingService.BEAN_NAME);
      IConsumerService consumerService = (IConsumerService) applicationContext.getBean(IConsumerService.KEY);
      IProviderService providerService = (IProviderService) applicationContext.getBean(IProviderService.BEAN_NAME);
      //create and get the engine
      PlayEngine engine = pss.createEngine(schedulingService, consumerService, providerService);
      //mock the message output
View Full Code Here

Examples of org.red5.server.api.scheduling.ISchedulingService

    boolean removed = listeners.remove(listener);
    if (!keepOnDisconnect) {
      if (removed && keepAliveJobName == null) {
        if (ScopeUtils.isRoom(this) && listeners.isEmpty()) {
          // create job to kill the scope off if no listeners join within the delay
          ISchedulingService schedulingService = (ISchedulingService) parent.getContext().getBean(ISchedulingService.BEAN_NAME);
          // by default keep a scope around for a fraction of a second
          keepAliveJobName = schedulingService.addScheduledOnceJob((keepDelay > 0 ? keepDelay * 1000 : 100), new KeepAliveJob(this));
        }
      }
    } else {
      log.trace("Scope: {} is exempt from removal when empty", getName());
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.