private void addOtherDeployedScanTargets( final ReadableArchive archive, final Attributes mainAttrs, Map<String,ReadableArchive> candidates) throws IOException { final String otherPUScanTargets = mainAttrs.getValue( AppClientArchivist.GLASSFISH_CLIENT_PU_SCAN_TARGETS_NAME); /* * Include library JARs - listed in the facade's Class-Path - and * any additional (typically top-level) JARs to be scanned. */ addScanTargetsFromURIList(archive, otherPUScanTargets, candidates); }
URI clientURI = clientURI(archive, acDescr); candidatePersistenceArchives.put(clientURI.toASCIIString(), archive); if (isDeployed(mainAttrs)) { if ( ! isDeployedClientAlsoStandAlone(mainAttrs)) { addOtherDeployedScanTargets(archive, mainAttrs, candidatePersistenceArchives); } else if ( ! isStandAlone(acDescr)) { addOtherNondeployedScanTargets(archive, acDescr, candidatePersistenceArchives); readPersistenceDeploymentDescriptor(main, pathToArchiveEntry.getValue(), pathToArchiveEntry.getKey(),
private URI clientURI(final ReadableArchive archive, final ApplicationClientDescriptor acDesc) throws IOException { if (archive instanceof MultiReadableArchive) { /* * Getting the manifest from a MultiReadableArchive returns the * manifest from the facade. */ final Manifest facadeMF = archive.getManifest(); final Attributes facadeMainAttrs = facadeMF.getMainAttributes(); final URI clientRelativeURI = URI.create( facadeMainAttrs.getValue(AppClientArchivist.GLASSFISH_APPCLIENT)); if (isDeployedClientAlsoStandAlone(facadeMainAttrs)) { return clientRelativeURI; } /* * We need the relative URI to the developer's client JAR within * the download directory. */ final URI absURIToClient = ((MultiReadableArchive) archive).getURI(1); final String relativeURIPathToAnchorDir = facadeMainAttrs.getValue(AppClientArchivist.GLASSFISH_ANCHOR_DIR); final URI absURIToAnchorDir = archive.getURI().resolve(relativeURIPathToAnchorDir); return absURIToAnchorDir.relativize(absURIToClient); } return archive.getURI(); }
URI clientURI = clientURI(archive, acDescr); candidatePersistenceArchives.put(clientURI.toASCIIString(), archive); if (isDeployed(mainAttrs)) { if ( ! isDeployedClientAlsoStandAlone(mainAttrs)) { addOtherDeployedScanTargets(archive, mainAttrs, candidatePersistenceArchives); } else if ( ! isStandAlone(acDescr)) { addOtherNondeployedScanTargets(archive, acDescr, candidatePersistenceArchives); readPersistenceDeploymentDescriptor(main, pathToArchiveEntry.getValue(), pathToArchiveEntry.getKey(),
private URI clientURI(final ReadableArchive archive, final ApplicationClientDescriptor acDesc) throws IOException { if (archive instanceof MultiReadableArchive) { /* * Getting the manifest from a MultiReadableArchive returns the * manifest from the facade. */ final Manifest facadeMF = archive.getManifest(); final Attributes facadeMainAttrs = facadeMF.getMainAttributes(); final URI clientRelativeURI = URI.create( facadeMainAttrs.getValue(AppClientArchivist.GLASSFISH_APPCLIENT)); if (isDeployedClientAlsoStandAlone(facadeMainAttrs)) { return clientRelativeURI; } /* * We need the relative URI to the developer's client JAR within * the download directory. */ final URI absURIToClient = ((MultiReadableArchive) archive).getURI(1); final String relativeURIPathToAnchorDir = facadeMainAttrs.getValue(AppClientArchivist.GLASSFISH_ANCHOR_DIR); final URI absURIToAnchorDir = archive.getURI().resolve(relativeURIPathToAnchorDir); return absURIToAnchorDir.relativize(absURIToClient); } return archive.getURI(); }
private void addOtherDeployedScanTargets( final ReadableArchive archive, final Attributes mainAttrs, Map<String,ReadableArchive> candidates) throws IOException { final String otherPUScanTargets = mainAttrs.getValue( AppClientArchivist.GLASSFISH_CLIENT_PU_SCAN_TARGETS_NAME); /* * Include library JARs - listed in the facade's Class-Path - and * any additional (typically top-level) JARs to be scanned. */ addScanTargetsFromURIList(archive, otherPUScanTargets, candidates); }