Examples of Result


Examples of gherkin.formatter.model.Result

        Step step2 = step("Given", "Step 2");
        final byte[] data1 = new byte[] {1, 2, 3};
        String text1 = "text1";
        String text2 = "text2";
        final byte[] data2 = new byte[] {4};
        Result step1Result = result("passed");
        Result step2Result = result("failed");

        jsonFormatter.uri(uri());
        jsonFormatter.feature(feature);
        jsonFormatter.startOfScenarioLifeCycle(scenario);
        jsonFormatter.before(match(), result("passed"));
View Full Code Here

Examples of gnu.testlet.runner.Result

        return checkResults;
    }
   
    private Result getResult(Result result1, Iterator results2) {
        final String name1 = result1.getName();
        Result result2 = null;
       
        while (results2.hasNext()) {
            Result res2 = (Result) results2.next();
            if (name1.equals(res2.getName())) {
                result2 = res2;
                break;
            }
        }
       
View Full Code Here

Examples of gov.nih.nlm.nls.metamap.Result

    term = term.replaceAll("\"", "");
     
   
   
    List<Result> resultList = api.processCitationsFromString(term);
      Result result = resultList.get(0);
    for (Utterance utterance: result.getUtteranceList())
    {  for (PCM pcm: utterance.getPCMList()) {
            /*for (Ev ev: pcm.getCandidatesInstance().getEvList()) {
                System.out.println(" Candidate:");
                System.out.println("  Score: " + ev.getScore());
                System.out.println("  Concept Id: " + ev.getConceptId());
View Full Code Here

Examples of gov.nysenate.openleg.model.Result

                HashMap<String,String> fields = new HashMap<String,String>();
                for(IndexableField field : doc.getFields()) {
                    fields.put(field.name(), doc.get(field.name()));
                }

                response.addResult(new Result(
                        doc.get("otype"),
                        doc.get("odata"),
                        doc.get("oid"),
                        Long.parseLong(lastModified),
                        Boolean.parseBoolean(doc.get("active")),
View Full Code Here

Examples of gsearch.Result

        Client c = new Client();

        List<Result> lolcats = c.searchImages("eu nao sei");
        for (int i = 0; i < lolcats.size(); i++) {
            try {
                Result rs = lolcats.get(i);
                URL link = new URL(rs.getUrl());

                File file = new File("/home/manchini/nomeAlbum" + i + ".jpg");
//Serve the file
                InputStream in = link.openStream();
                FileOutputStream out = new FileOutputStream(file);
View Full Code Here

Examples of hu.u_szeged.nbo.common.Result

        user.getUserName() + "'s task: " + task + ".", 1);
   
    Solver solver = new Solver();
    solver.solve(this.task);
   
    Result result = new Result(this.uniqueHash, this.problemName);
    result.add(this.problemName, solver.getOutput());
   
    try {
      for (String filename: new String[] { "eredmeny.txt", "ertekeles.txt", "kimaradt_munkak.txt" }) {
        String fileData;
        //System.out.println(System.getProperty("user.dir") + this.pathOfTask + "/" + filename);
        File file = new File(this.pathOfTask + "/" + filename);
        char buffer[] = new char[(int)file.length()];
        FileReader fileReader = new FileReader(file);
        fileReader.read(buffer);
        fileData = new String(buffer);
        result.add(filename, fileData);
     

      user.getLogs().put(this.uniqueHash, solver.getLog());

      NBOServer.log("ResourceAllocationSolver FINISHED " +
View Full Code Here

Examples of hudson.model.Result

        super(sendToList, sendToDevs, sendToRequester, sendToCulprits,recipientList, replyTo, subject, body, attachmentsPattern, attachBuildLog, contentType);
    }

    @Override
    public boolean trigger(AbstractBuild<?, ?> build, TaskListener listener) {
        Result buildResult = build.getResult();
        if (buildResult == Result.FAILURE) {
            return true;
        }
        return false;
    }
View Full Code Here

Examples of io.druid.query.Result

                        final String segmentId,
                        final Interval interval,
                        final Iterable<Result<TimeseriesResultValue>> results
                    )
                    {
                      return new Result(
                          results.iterator().next().getTimestamp(),
                          new BySegmentResultValueClass(
                              Lists.newArrayList(results),
                              segmentId,
                              interval
View Full Code Here

Examples of io.fabric8.patch.Result

            close(fos);
        }
    }

    void rollback(Patch patch, boolean force) throws PatchException {
        Result result = patch.getResult();
        if (result == null) {
            throw new PatchException("Patch " + patch.getId() + " is not installed");
        }
        Bundle[] allBundles = bundleContext.getBundles();
        List<BundleUpdate> badUpdates = new ArrayList<BundleUpdate>();
        for (BundleUpdate update : result.getUpdates()) {
            boolean found = false;
            Version v = Version.parseVersion(update.getNewVersion());
            for (Bundle bundle : allBundles) {
                if (stripSymbolicName(bundle.getSymbolicName()).equals(stripSymbolicName(update.getSymbolicName()))
                        && bundle.getVersion().equals(v)) {
                    found = true;
                    break;
                }
            }
            if (!found) {
                badUpdates.add(update);
            }
        }
        if (!badUpdates.isEmpty() && !force) {
            StringBuilder sb = new StringBuilder();
            sb.append("Unable to rollback patch ").append(patch.getId()).append(" because of the following missing bundles:\n");
            for (BundleUpdate up : badUpdates) {
                sb.append("\t").append(up.getSymbolicName()).append("/").append(up.getNewVersion()).append("\n");
            }
            throw new PatchException(sb.toString());
        }

        Map<Bundle, String> toUpdate = new HashMap<Bundle, String>();
        for (BundleUpdate update : result.getUpdates()) {
            Version v = Version.parseVersion(update.getNewVersion());
            for (Bundle bundle : allBundles) {
                if (stripSymbolicName(bundle.getSymbolicName()).equals(stripSymbolicName(update.getSymbolicName()))
                        && bundle.getVersion().equals(v)) {
                    toUpdate.put(bundle, update.getPreviousLocation());
                }
            }
        }
        try {
            applyChanges(toUpdate);
            writeFully(new File(System.getProperty("karaf.base"), "etc/startup.properties"), ((ResultImpl) result).getStartup());
            writeFully(new File(System.getProperty("karaf.base"), "etc/overrides.properties"), ((ResultImpl) result).getOverrides());
        } catch (Exception e) {
            throw new PatchException("Unable to rollback patch " + patch.getId() + ": " + e.getMessage(), e);
        }
        ((PatchImpl) patch).setResult(null);
        File file = new File(patchDir, result.getPatch().getId() + ".patch.result");
        file.delete();
    }
View Full Code Here

Examples of jade.content.onto.annotations.Result

  }
 
  private void manageActionResult(Class clazz, ObjectSchema schema, boolean buildHierarchy) throws OntologyException {
    Annotation annotation;
    if ((annotation = clazz.getAnnotation(Result.class)) != null) {
      Result r = (Result)annotation;
      TermSchema ts = (TermSchema)doAddSchema(r.type(), buildHierarchy);
      ((AgentActionSchema)schema).setResult(ts);
    } else if ((annotation = clazz.getAnnotation(AggregateResult.class)) != null) {
      AggregateResult ar = (AggregateResult)annotation;
      TermSchema ts = (TermSchema)doAddSchema(ar.type(), buildHierarchy);
      ((AgentActionSchema)schema).setResult(ts, ar.cardMin(), ar.cardMax());
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.