Examples of loadMapping()


Examples of edu.umd.cloud9.collection.DocnoMapping.loadMapping()

      LOG.info(" - Class name: " + className);
      mDocMapping = (DocnoMapping) Class.forName(className).newInstance();

      Path mappingFile = env.getDocnoMappingData();
      LOG.info(" - File name: " + mappingFile);
      mDocMapping.loadMapping(mappingFile, fs);
      LOG.info("Done!");
    } catch (Exception e) {
      throw new IOException("Error initializing DocnoMapping!");
    }
    return mDocMapping;
View Full Code Here

Examples of edu.umd.cloud9.collection.clue.ClueWarcDocnoMapping.loadMapping()

        "-" + DocnoMapping.BuilderUtils.MAPPING_OPTION + "=" + mappingFile };

    IntegrationUtils.exec(Joiner.on(" ").join(args));

    ClueWarcDocnoMapping mapping = new ClueWarcDocnoMapping();
    mapping.loadMapping(new Path(mappingFile), fs);

    assertEquals("clueweb09-en0000-00-00000", mapping.getDocid(1));
    assertEquals("clueweb09-en0000-29-13313", mapping.getDocid(1000000));

    assertEquals(1, mapping.getDocno("clueweb09-en0000-00-00000"));
View Full Code Here

Examples of edu.umd.cloud9.collection.medline.MedlineDocnoMapping.loadMapping()

        "-" + DocnoMapping.BuilderUtils.MAPPING_OPTION + "=" + mappingFile };

    IntegrationUtils.exec(Joiner.on(" ").join(args));

    MedlineDocnoMapping mapping = new MedlineDocnoMapping();
    mapping.loadMapping(new Path(mappingFile), fs);

    assertEquals("45641", mapping.getDocid(1));
    assertEquals("45740", mapping.getDocid(100));
    assertEquals("7472623", mapping.getDocid(10000));
    assertEquals("8739651", mapping.getDocid(1000000));
View Full Code Here

Examples of edu.umd.cloud9.collection.trec.TrecDocnoMapping.loadMapping()

        "-" + DocnoMapping.BuilderUtils.MAPPING_OPTION + "=" + mappingFile };

    IntegrationUtils.exec(Joiner.on(" ").join(args));

    TrecDocnoMapping mapping = new TrecDocnoMapping();
    mapping.loadMapping(new Path(mappingFile), fs);

    assertEquals("FBIS3-1", mapping.getDocid(1));
    assertEquals("LA061490-0139", mapping.getDocid(400000));

    assertEquals(1, mapping.getDocno("FBIS3-1"));
View Full Code Here

Examples of edu.umd.cloud9.collection.trecweb.Gov2DocnoMapping.loadMapping()

        "-" + DocnoMapping.BuilderUtils.MAPPING_OPTION + "=" + gov2MappingFile };

    IntegrationUtils.exec(Joiner.on(" ").join(args));

    Gov2DocnoMapping mapping = new Gov2DocnoMapping();
    mapping.loadMapping(new Path(gov2MappingFile), fs);

    assertEquals("GX000-00-0000000", mapping.getDocid(1));
    assertEquals("GX210-38-0737901", mapping.getDocid(20000000));

    assertEquals(1, mapping.getDocno("GX000-00-0000000"));
View Full Code Here

Examples of edu.umd.cloud9.collection.trecweb.Wt10gDocnoMapping.loadMapping()

        "-" + DocnoMapping.BuilderUtils.MAPPING_OPTION + "=" + wt10gMappingFile };

    IntegrationUtils.exec(Joiner.on(" ").join(args));

    Wt10gDocnoMapping mapping = new Wt10gDocnoMapping();
    mapping.loadMapping(new Path(wt10gMappingFile), fs);

    assertEquals("WTX001-B01-1", mapping.getDocid(1));
    assertEquals("WTX062-B34-37", mapping.getDocid(1000000));

    assertEquals(1, mapping.getDocno("WTX001-B01-1"));
View Full Code Here

Examples of edu.umd.cloud9.collection.wikipedia.WikipediaDocnoMapping.loadMapping()

    };

    List<Integer> counts = IntegrationUtils.execWiki(Joiner.on(" ").join(args));

    WikipediaDocnoMapping mapping = new WikipediaDocnoMapping();
    mapping.loadMapping(new Path(mappingFile), fs);

    System.out.println("DISAMBIGUATION = " + numDisamb + "; ARTICLE = " + numArticles + "; TOTAL = " + total);
    System.out.println("DOCNO 0 = " + mapping.getDocid(1));
    System.out.println("DOCNO 100000 = " + mapping.getDocid(100000));
View Full Code Here

Examples of org.apache.jetspeed.util.SynchronizedMapping.loadMapping()

        try
        {
            Mapping mapping = new SynchronizedMapping();
            InputSource is = new InputSource(new FileReader(map));
            is.setSystemId(mapFile);
            mapping.loadMapping(is);
           
            DocumentBuilderFactory dbfactory = DocumentBuilderFactory.newInstance();
            DocumentBuilder builder = dbfactory.newDocumentBuilder();
      
            Document d = builder.parse(new File(registryFile));
View Full Code Here

Examples of org.exolab.castor.mapping.Mapping.loadMapping()

    File f1 = new File(mappingfile);

    if (f1.exists()) {
      Mapping mapping = new Mapping();
      try {
  mapping.loadMapping(mappingfile);
  Writer writer = new FileWriter(filename);
  Marshaller marshaller = new Marshaller(writer);
  marshaller.setMapping(mapping);
  marshaller.marshal(this);
  writer.close();
View Full Code Here

Examples of org.exolab.castor.mapping.Mapping.loadMapping()

    File f2 = new File(configDirectory+File.separatorChar+xmlconfig);

    if (f1.exists() && f2.exists()) {
      Mapping mapping = new Mapping();
      try {
  mapping.loadMapping(f1.getPath());
  Unmarshaller unmar = new Unmarshaller(mapping);
  unmar.setDebug(true);
  baseobj=(JoBoBase)unmar.unmarshal(new InputSource(f2.getPath()));
 
  log.info("configured from XML");
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.