@Test public void testSetWhereEmptyUrl() throws Exception { final QuarantineService q = new LaunchServicesQuarantineService(); q.setWhereFrom(new NullLocal("/", "n"), null); q.setWhereFrom(new NullLocal("/", "n"), StringUtils.EMPTY); }
@Override public void setWhereFrom(final Local file, final String dataUrl) throws LocalAccessDeniedException { synchronized(lock) { if(StringUtils.isBlank(dataUrl)) { log.warn("No data url given"); return; } if(!this.setWhereFrom(file.getAbsolute(), dataUrl)) { throw new LocalAccessDeniedException(file.getAbsolute()); } } }
LaunchServicesQuarantineService implements QuarantineService { @Override public void setWhereFrom(final Local file, final String dataUrl) throws LocalAccessDeniedException { synchronized(lock) { if(StringUtils.isBlank(dataUrl)) { log.warn("No data url given"); return; } if(!this.setWhereFrom(file.getAbsolute(), dataUrl)) { throw new LocalAccessDeniedException(file.getAbsolute()); } } } }
LaunchServicesQuarantineService implements QuarantineService { @Override public void setWhereFrom(final Local file, final String dataUrl) throws LocalAccessDeniedException { synchronized(lock) { if(StringUtils.isBlank(dataUrl)) { log.warn("No data url given"); return; } if(!this.setWhereFrom(file.getAbsolute(), dataUrl)) { throw new LocalAccessDeniedException(file.getAbsolute()); } } }  }
LaunchServicesQuarantineService implements QuarantineService { @Override public void setWhereFrom(final Local file, final String dataUrl) throws LocalAccessDeniedException { synchronized(lock) { if(StringUtils.isBlank(dataUrl)) { log.warn("No data url given"); return; } if(!this.setWhereFrom(file.getAbsolute(), dataUrl)) { throw new LocalAccessDeniedException(file.getAbsolute()); } } }  @Override void setQuarantine(final Local file, final String originUrl, final String dataUrl); @Override void setWhereFrom(final Local file, final String dataUrl); }
LaunchServicesQuarantineService implements QuarantineService { @Override public void setWhereFrom(final Local file, final String dataUrl) throws LocalAccessDeniedException { synchronized(lock) { if(StringUtils.isBlank(dataUrl)) { log.warn("No data url given"); return; } if(!this.setWhereFrom(file.getAbsolute(), dataUrl)) { throw new LocalAccessDeniedException(file.getAbsolute()); } } }  @Override void setQuarantine(final Local file, final String originUrl, final String dataUrl); @Override void setWhereFrom(final Local file, final String dataUrl);  }