Package com.oracle.truffle.api.source

Examples of com.oracle.truffle.api.source.Source


        rubiniusLibrary = new RubiniusLibrary(this);
    }

    public void loadRubyCore(String fileName) {
        final Source source;

        try {
            source = Source.fromReader(new InputStreamReader(context.getRuntime().getLoadService().getClassPathResource(context.getRuntime().getJRubyClassLoader(), fileName).getInputStream()), fileName);
        } catch (IOException e) {
            throw new RuntimeException(e);
View Full Code Here


            @Override
            public Object get() {
                final String inputFile = rootNode.getPosition().getFile();

                final Source source;

                if (inputFile.equals("-e")) {
                    // Assume UTF-8 for the moment
                    source = Source.fromBytes(runtime.getInstanceConfig().inlineScript(), "-e", new BytesDecoder.UTF8BytesDecoder());
                } else {
View Full Code Here

TOP

Related Classes of com.oracle.truffle.api.source.Source

Copyright © 2018 www.massapicom. 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.