Examples of asFile()


Examples of org.jboss.shrinkwrap.resolver.api.maven.MavenResolvedArtifact.asFile()

        final String version = coordinate.getVersion();
        final String resolvedVersion = shortcut.getResolvedVersion();
        final String type = coordinate.getType().toString();
        final boolean isSnapshot = shortcut.isSnapshotVersion();
        final String classifier = coordinate.getClassifier();
        final File file = shortcut.asFile();
        final File file2 = shortcut.as(File.class);
        final InputStream in = shortcut.as(InputStream.class);
        final InputStream in2 = shortcut.as(InputStream.class);
        final JavaArchive archive = shortcut.as(JavaArchive.class);
    }
View Full Code Here

Examples of org.jboss.shrinkwrap.resolver.api.maven.MavenResolvedArtifact.asFile()

        // picks it up)
        final MavenResolvedArtifact artifact = Maven.resolver().loadPomFromFile("pom.xml")
                .resolve("org.jboss.shrinkwrap.resolver:shrinkwrap-resolver-impl-maven:" + expectedVersion)
                .withoutTransitivity().asSingleResolvedArtifact();

        final String resolvedFilename = artifact.asFile().getName();

        Assert.assertTrue("Incorrect version was resolved", resolvedFilename.contains(expectedVersion));
    }

}
View Full Code Here

Examples of org.overlord.commons.osgi.vfs.VfsBundle.asFile()

            ServiceReference serviceReference = bundleContext.getServiceReference(IVfsBundleFactory.class.getName());
            if (serviceReference == null)
                throw new RuntimeException("OSGi Service Reference for [IVfsBundleFactory] not found."); //$NON-NLS-1$
            IVfsBundleFactory vfsBundleFactory = (IVfsBundleFactory) bundleContext.getService(serviceReference);
            VfsBundle bundle = vfsBundleFactory.getVfsBundle(url);
            File vfsFile = bundle.asFile(url);
            try {
                if (vfsFile.isFile()) {
                    return new ZipDir(vfsFile.toURI().toURL());
                }
                if (vfsFile.isDirectory()) {
View Full Code Here

Examples of play.mvc.Http.RawBuffer.asFile()

        // as Integer.MAX_VALUE in play.core.j.JavaParsers.raw method, the
        // content is stored as a file.
        if (buf != null) {
            in = new ByteArrayInputStream(buf);
        } else {
            File file = raw.asFile();
            if (file == null) {
                // asFile() may return null if the raw body is larger than the limit defined by
                // BodyParser.of annotation at SvnApp.service() method.
                throw new IOException("Request entity is too large.");
            }
View Full Code Here

Examples of play.mvc.Http.RawBuffer.asFile()

            // which is defined as 100 * 1024 in play.api.mvc.BodyParsers trait,
            // the content is stored as a file.
            if (buf != null) {
                requestStream = new ByteArrayInputStream(buf);
            } else {
                requestStream = new FileInputStream(raw.asFile());
            }

            Repository repository;
            PipedInputStream responseStream = new PipedInputStream();

View Full Code Here

Examples of ptolemy.data.expr.FileParameter.asFile()

                DefaultModelAttribute attribute = (DefaultModelAttribute) pattern
                        .getAttribute("DefaultModel");
                if (attribute != null) {
                    FileParameter parameter = (FileParameter) attribute.parameter;
                    if (parameter.getExpression() != null) {
                        modelFile = parameter.asFile();
                    }
                }

                if (modelFile == null) {
                    ComponentDialog dialog = new ComponentDialog(
View Full Code Here

Examples of ptolemy.data.expr.FileParameter.asFile()

                        //                         effigy.masterEffigy().setModifiable(true);
                        //                         System.out.println("FileOrURLEditorFactory: modifiable"
                        //                                            + effigy.isModifiable() + " " + effigy);

                    } else {
                        URL fileURL = fileOrURLParameter.asFile().toURI()
                                .toURL();
                        configuration.openModel(null, fileURL, fileURL
                                .toExternalForm());
                    }
                } catch (Exception ex) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.