Package org.apache.aries.blueprint.utils.threading.impl

Examples of org.apache.aries.blueprint.utils.threading.impl.DiscardableRunnable.discard()


        {
          DiscardableRunnable t = new DiscardableRunnable(task, _unprocessedWork);
          try {
            return new WrappedFuture(_current.get().submit(t), t);
          } catch (RuntimeException e) {
            t.discard();
            throw e;
          }
        }
      });
    } catch (Exception e) { throw new RejectedExecutionException(); }
View Full Code Here


        {
          DiscardableRunnable t = new DiscardableRunnable(task, _unprocessedWork);
          try {
            return new WrappedFuture<T>(_current.get().submit(t, result), t);
          } catch (RuntimeException e) {
            t.discard();
            throw e;
          }
        }
      });
    } catch (Exception e) { throw new RejectedExecutionException(); }
View Full Code Here

        {
          DiscardableRunnable t = new DiscardableRunnable(command, _unprocessedWork);
          try {
            _current.get().execute(t);
          } catch (RuntimeException e) {
            t.discard();
            throw e;
          }
          return null;
        }
      });
View Full Code Here

        {
          DiscardableRunnable t = new DiscardableRunnable(command, _unprocessedWork);
          try {
            return new WrappedScheduledFuture(_current.get().schedule(t, delay, unit), t);
          } catch (RuntimeException e) {
            t.discard();
            throw e;
          }
        }
      });
    } catch (Exception e) { throw new RejectedExecutionException(); }
View Full Code Here

        {
          DiscardableRunnable t = new DiscardableRunnable(command, _unprocessedWork);
          try {
            return new WrappedScheduledFuture(_current.get().scheduleAtFixedRate(t, initialDelay, period, unit), t);
          } catch (RuntimeException e) {
            t.discard();
            throw e;
          }
        }
      });
    } catch (Exception e) { throw new RejectedExecutionException(); }
View Full Code Here

        {
          DiscardableRunnable t = new DiscardableRunnable(command, _unprocessedWork);
          try {
            return new WrappedScheduledFuture(_current.get().scheduleWithFixedDelay(t, initialDelay, delay, unit), t);
          } catch (RuntimeException e) {
            t.discard();
            throw e;
          }
        }
      });
    } catch (Exception e) { throw new RejectedExecutionException(); }
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.