uris.relativeURI.toASCIIString(), uris.absoluteURI.toASCIIString(), existingArtifact.getFull().toASCIIString()) ); new Artifacts.FullAndPartURIs( uris.absoluteURI, uris.relativeURI); artifacts.put(uris.relativeURI, newArtifact);
/** * Adds an artifact. * @param full the full URI to the file to be tracked * @param part the (typically) relative URI to be associated with the part * (a frequent use of Artifacts is for working with Payloads which are * composed of parts - hence the "part" term) */ public synchronized void addArtifact(URI full, URI part) { FullAndPartURIs fullAndPart = new FullAndPartURIs(full, part); artifacts.add(fullAndPart); if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "Added {1} artifact: {0}", new Object[] {fullAndPart, keyPrefix}); } }
/** * Records the artifacts in the provided Properties object. * * @param props * @throws URISyntaxException */ public synchronized void record( final Properties props) throws URISyntaxException { for (Artifacts.FullAndPartURIs artifactInfo : artifacts) { props.setProperty( propName(artifactInfo.getPart()), propValue(artifactInfo.getFull())); } }