Exemplo n.º 1
0
 /** Shuts down the adaptor. */
 @After
 public void tearDown() {
   try {
     this.adaptor.shutdown();
   } catch (PluginException e) {
     e.printStackTrace();
   }
   this.removeCacheFile();
 }
Exemplo n.º 2
0
  /** Creates the adaptor and initalizes it. */
  @Before
  public void setup() {
    this.createCacheFile();
    this.adaptor = new PronomAdaptor();
    try {
      this.adaptor.init();

      final Map<String, String> config = new HashMap<String, String>();
      config.put("pronom.cache.file.path", this.cache.getAbsolutePath());
      config.put("pronom.batch.size", "5");
      this.adaptor.setParameterValues(config);
    } catch (PluginException e) {
      e.printStackTrace();
    } catch (InvalidParameterException e) {
      e.printStackTrace();
    }
  }