/** * Return the input stream to artifact. * * @return prepared input stream * * @throws IOException re-thrown * @see org.ops4j.net.URLUtils#prepareInputStream(java.net.URL,boolean) */ InputStream getInputStream() throws IOException { return URLUtils.prepareInputStream( m_artifactURL, !m_checkCertificate ); }
/** * {@inheritDoc} */ @Override public InputStream getDefinition( final Configuration configuration ) throws IOException { return URLUtils.prepareInputStream( new URL( configuration.getProperty( "equinox.snapshot.definition.url" ) ), true ); }
/** * {@inheritDoc} */ @Override public InputStream getDefinition( final Configuration configuration ) throws IOException { return URLUtils.prepareInputStream( new URL( configuration.getProperty( "felix.snapshot.definition.url" ) ), true ); }
/** * {@inheritDoc} */ @Override public InputStream getDefinition( final Configuration configuration ) throws IOException { return URLUtils.prepareInputStream( new URL( configuration.getProperty( "concierge.snapshot.definition.url" ) ), true ); }
/** * {@inheritDoc} */ @Override public InputStream getDefinition( final Configuration configuration ) throws IOException { return URLUtils.prepareInputStream( new URL( configuration.getProperty( "knopflerfish.snapshot.definition.url" ) ), true ); }
try is = URLUtils.prepareInputStream( bndFileURL, true ); m_wrappingProperties.load( is );
/** * @param repositoryURL url to reporsitory * @param path a path to the artifact jar file * * @return prepared input stream * * @throws IOException re-thrown * @see org.ops4j.net.URLUtils#prepareInputStream(java.net.URL,boolean) */ private InputStream prepareInputStream( URL repositoryURL, final String path ) throws IOException { String repository = repositoryURL.toExternalForm(); if( !repository.endsWith( Parser.FILE_SEPARATOR ) ) { repository = repository + Parser.FILE_SEPARATOR; } m_configuration.enableProxy( repositoryURL ); final URL url = new URL( repository + path ); LOG.trace( "Reading " + url.toExternalForm() ); return URLUtils.prepareInputStream( url, !m_configuration.getCertificateCheck() ); }
/** * Url must be a reference to an instructions file. * * @see AbstractConnection#getInstructions() */ protected Properties getInstructions() throws IOException { final Properties instructions = new Properties(); final URL instructionsFleUrl = getInstructionsFileURL(); instructions.load( URLUtils.prepareInputStream( instructionsFleUrl, !getConfiguration().getCertificateCheck() ) ); //the following line is for debugging purposes //instructions.store( System.out, null ); return instructions; }
/** * Returns the {@link Jar} if exists and is valid or creates on from scratch. * @return the {@link Jar} that corresponds to the object properties. * @throws Exception */ private Jar getOrCreateJar() throws Exception { if (this.jar != null && jar.getResources() != null) { return jar; } else { return BndUtils.createJar( URLUtils.prepareInputStream(new URL(fabUri), configuration.getCertificateCheck()), instructions, fabUri, OverwriteMode.MERGE, embeddedResources, classPathResolver.getExtraImportPackages(), actualImports, this); } }
/** * Returns the {@link Jar} if exists and is valid or creates on from scratch. * @return the {@link Jar} that corresponds to the object properties. * @throws Exception */ private Jar getOrCreateJar() throws Exception { if (this.jar != null && jar.getResources() != null) { return jar; } else { return BndUtils.createJar( URLUtils.prepareInputStream(new URL(fabUri), configuration.getCertificateCheck()), instructions, fabUri, OverwriteMode.MERGE, embeddedResources, classPathResolver.getExtraImportPackages(), actualImports, this); } }
URLUtils.prepareInputStream(new URL(warUri), !m_configuration.getCertificateCheck()), instructions, warUri );
/** * Returns an input stream for the bundle created from the jar. * * @return the input stream for the bundle created from the jar * * @throws IOException re-thrown from BndLib.createBundle * @see BndUtils#createBundle(InputStream, Properties, String) */ @Override public InputStream getInputStream() throws IOException { connect(); return BndUtils.createBundle( URLUtils.prepareInputStream( m_parser.getWrappedJarURL(), !m_configuration.getCertificateCheck() ), m_parser.getWrappingProperties(), url.toExternalForm(), m_parser.getOverwriteMode() ); }