org.apache.shiro.concurrent
Class SubjectAwareScheduledExecutorService

java.lang.Object
  extended by org.apache.shiro.concurrent.SubjectAwareExecutor
      extended by org.apache.shiro.concurrent.SubjectAwareExecutorService
          extended by org.apache.shiro.concurrent.SubjectAwareScheduledExecutorService
All Implemented Interfaces:
Executor, ExecutorService, ScheduledExecutorService

public class SubjectAwareScheduledExecutorService
extends SubjectAwareExecutorService
implements ScheduledExecutorService

Same concept as the SubjectAwareExecutorService but additionally supports the ScheduledExecutorService interface.


Constructor Summary
SubjectAwareScheduledExecutorService()
           
SubjectAwareScheduledExecutorService(ScheduledExecutorService target)
           
 
Method Summary
 ScheduledExecutorService getTargetScheduledExecutorService()
           
<V> ScheduledFuture<V>
schedule(Callable<V> callable, long delay, TimeUnit unit)
           
 ScheduledFuture<?> schedule(Runnable command, long delay, TimeUnit unit)
           
 ScheduledFuture<?> scheduleAtFixedRate(Runnable command, long initialDelay, long period, TimeUnit unit)
           
 ScheduledFuture<?> scheduleWithFixedDelay(Runnable command, long initialDelay, long delay, TimeUnit unit)
           
 void setTargetExecutor(Executor targetExecutor)
          Sets target Executor instance that will actually execute the subject-associated Runnable instances.
 void setTargetExecutorService(ExecutorService targetExecutorService)
           
 void setTargetScheduledExecutorService(ScheduledExecutorService targetScheduledExecutorService)
           
 
Methods inherited from class org.apache.shiro.concurrent.SubjectAwareExecutorService
associateWithSubject, associateWithSubject, awaitTermination, getTargetExecutorService, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated, shutdown, shutdownNow, submit, submit, submit
 
Methods inherited from class org.apache.shiro.concurrent.SubjectAwareExecutor
associateWithSubject, execute, getSubject, getTargetExecutor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.concurrent.ExecutorService
awaitTermination, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated, shutdown, shutdownNow, submit, submit, submit
 
Methods inherited from interface java.util.concurrent.Executor
execute
 

Constructor Detail

SubjectAwareScheduledExecutorService

public SubjectAwareScheduledExecutorService()

SubjectAwareScheduledExecutorService

public SubjectAwareScheduledExecutorService(ScheduledExecutorService target)
Method Detail

getTargetScheduledExecutorService

public ScheduledExecutorService getTargetScheduledExecutorService()

setTargetScheduledExecutorService

public void setTargetScheduledExecutorService(ScheduledExecutorService targetScheduledExecutorService)

setTargetExecutor

public void setTargetExecutor(Executor targetExecutor)
Description copied from class: SubjectAwareExecutor
Sets target Executor instance that will actually execute the subject-associated Runnable instances.

Overrides:
setTargetExecutor in class SubjectAwareExecutorService
Parameters:
targetExecutor - the target Executor instance that will actually execute the subject-associated Runnable instances.

setTargetExecutorService

public void setTargetExecutorService(ExecutorService targetExecutorService)
Overrides:
setTargetExecutorService in class SubjectAwareExecutorService

schedule

public ScheduledFuture<?> schedule(Runnable command,
                                   long delay,
                                   TimeUnit unit)
Specified by:
schedule in interface ScheduledExecutorService

schedule

public <V> ScheduledFuture<V> schedule(Callable<V> callable,
                                       long delay,
                                       TimeUnit unit)
Specified by:
schedule in interface ScheduledExecutorService

scheduleAtFixedRate

public ScheduledFuture<?> scheduleAtFixedRate(Runnable command,
                                              long initialDelay,
                                              long period,
                                              TimeUnit unit)
Specified by:
scheduleAtFixedRate in interface ScheduledExecutorService

scheduleWithFixedDelay

public ScheduledFuture<?> scheduleWithFixedDelay(Runnable command,
                                                 long initialDelay,
                                                 long delay,
                                                 TimeUnit unit)
Specified by:
scheduleWithFixedDelay in interface ScheduledExecutorService


Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.