Examples of succeeded()


Examples of org.apache.sling.event.impl.jobs.JobExecutionResultImpl.succeeded()

                                        public void asyncProcessingFinished(final JobExecutionResult result) {
                                            synchronized ( lock ) {
                                                if ( isAsync.compareAndSet(true, false) ) {
                                                    services.jobConsumerManager.unregisterListener(job.getId());
                                                    Job.JobState state = null;
                                                    if ( result.succeeded() ) {
                                                        state = Job.JobState.SUCCEEDED;
                                                    } else if ( result.failed() ) {
                                                        state = Job.JobState.QUEUED;
                                                    } else if ( result.cancelled() ) {
                                                        if ( handler.isStopped() ) {
View Full Code Here

Examples of org.apache.sling.event.impl.jobs.JobExecutionResultImpl.succeeded()

                                    if ( result == null ) { // ASYNC processing
                                        services.jobConsumerManager.registerListener(job.getId(), consumer, ctx);
                                        asyncCounter.incrementAndGet();
                                        isAsync.set(true);
                                    } else {
                                        if ( result.succeeded() ) {
                                            resultState = Job.JobState.SUCCEEDED;
                                        } else if ( result.failed() ) {
                                            resultState = Job.JobState.QUEUED;
                                        } else if ( result.cancelled() ) {
                                            if ( handler.isStopped() ) {
View Full Code Here

Examples of org.cishell.testing.convertertester.core.tester2.reportgen.results.FilePassResult.succeeded()

       
        int[] trusted = new int[tr.getAllConverters().length];
        for (int jj = 0; jj < fprs.length; jj++) {
          FilePassResult fpr = fprs[jj];
         
          if (fpr.succeeded()) {
            for (int kk = 0; kk < trusted.length; kk++) {
              if (trusted[kk] != FAILED) {
                trusted[kk] += 1;
              }
            }
View Full Code Here

Examples of org.cishell.testing.convertertester.core.tester2.reportgen.results.FilePassResult.succeeded()

        /*
         * associate the file pass with the chance that each converter
         * involved is at fault.
         */
       
        if (! fp.succeeded()) {
          ChanceAtFault[] chanceAtFaults  = faultHeuristic.determine(fp,
              convsInvolved, trustedConvs);
          for (int kk = 0; kk < chanceAtFaults.length; kk++) {
            ChanceAtFault caf = chanceAtFaults[kk];
            fp.addChanceAtFault(caf);
View Full Code Here

Examples of org.eclipse.jetty.util.Callback.succeeded()

        Assert.assertEquals(1, contentCount.get());

        // Succeed the content callback to proceed with parsing.
        callbackRef.set(null);
        contentLatch.set(new CountDownLatch(1));
        callback.succeeded();

        Assert.assertTrue(contentLatch.get().await(5, TimeUnit.SECONDS));
        callback = callbackRef.get();

        // Wait a while to be sure that the parsing does not proceed.
View Full Code Here

Examples of org.eclipse.jetty.util.Callback.succeeded()

        Assert.assertEquals(1, completeLatch.getCount());

        // Succeed the content callback to proceed with parsing.
        callbackRef.set(null);
        contentLatch.set(new CountDownLatch(1));
        callback.succeeded();

        Assert.assertTrue(completeLatch.await(5, TimeUnit.SECONDS));
        Assert.assertEquals(2, contentCount.get());
    }
}
View Full Code Here

Examples of org.eclipse.jetty.util.Callback.succeeded()

            callback = null;
            state = WriteState.IDLE;
            // Call the callback only after the whole state has been reset,
            // because the callback may trigger a reentrant call and
            // the state must already be the new one that we reset here.
            c.succeeded();
        }

        @Override
        public void onError(Throwable failure)
        {
View Full Code Here

Examples of org.eclipse.jetty.util.Callback.succeeded()

            recycle();
            for (int i = 0; i < callbacks.size(); ++i)
            {
                Callback callback = callbacks.get(i);
                if (callback != null)
                    callback.succeeded();
            }
        }

        @Override
        @SuppressWarnings("ForLoopReplaceableByForEach")
View Full Code Here

Examples of org.eclipse.jetty.util.Callback.succeeded()

     */
    public void fillable()
    {
        Callback callback = _interested.get();
        if (callback != null && _interested.compareAndSet(callback, null))
            callback.succeeded();
    }

    /**
     * @return True if a read callback has been registered
     */
 
View Full Code Here

Examples of org.eclipse.jetty.util.FutureCallback.succeeded()

                FutureCallback shutdown = _shutdown.get();
                if (shutdown!=null)
                {
                    httpResponse.flushBuffer();
                    if (d==0)
                        shutdown.succeeded();
                }  
            }
            // else onCompletion will handle it.
        }
    }
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.