Package apex.jorje.services.printers

Examples of apex.jorje.services.printers.PrintContext


            printerFactory, ListPrinter.create(formalParameterPrinter, ", ", "", ""));
    private static OutlineViewPropertyClassMemberPrinter propertyMemberPrinter =
            new OutlineViewPropertyClassMemberPrinter(printerFactory);

    private PrintContext defaultPrintContext() {
        return new PrintContext();
    }
View Full Code Here


                            @Override
                            public Map<String, Object> _case(RealLoc loc) {
                                try {
                                    Map<String, Object> config = new HashMap<String, Object>();
                                    MarkerUtilities.setMessage(config, PrinterUtil.INSTANCE.getFactory()
                                            .userErrorPrinter().print(apexException.getError(), new PrintContext()));

                                    MarkerUtilities.setCharStart(config,
                                        ParserLocationTranslator.getStartOffset(loc, fDocument));
                                    MarkerUtilities.setCharEnd(config,
                                        ParserLocationTranslator.getEndOffset(loc, fDocument));

                                    config.put(IMarker.SEVERITY, IMarker.SEVERITY_ERROR);
                                    config.put(IMarker.LOCATION, fFile.getFullPath().toString());

                                    return config;
                                } catch (BadLocationException e) {
                                    return _default(error);
                                }
                            }

                            @Override
                            public Map<String, Object> _case(SyntheticLoc loc) {
                                return _default(error);
                            }
                        });
                    }

                    /*
                     * Everything else, just put on the first line since we don't have any other information
                     */
                    @Override
                    protected Map<String, Object> _default(SemanticError x) {
                        Map<String, Object> config = new HashMap<String, Object>();

                        MarkerUtilities.setLineNumber(config, 1);
                        // Need to implement the first, currently get a NotImplementedYet exception
                        MarkerUtilities.setMessage(
                            config,
                            PrinterUtil.INSTANCE.getFactory().userErrorPrinter()
                                    .print(apexException.getError(), new PrintContext()));

                        // Not sure why there aren't any utilities methods for these fields in MarkerUtilities
                        // Set them directly instead.
                        config.put(IMarker.SEVERITY, IMarker.SEVERITY_ERROR);
                        config.put(IMarker.LOCATION, fFile.getFullPath().toString());
View Full Code Here

TOP

Related Classes of apex.jorje.services.printers.PrintContext

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.