Package org.apache.flex.compiler.common

Examples of org.apache.flex.compiler.common.ISourceLocation


     * {@link PooledValue} if it was already of the correct type.
     */
    public PooledValue checkInitialValue(IVariableNode iNode, Binding type, PooledValue initial_value)
    {
        assert initial_value != null : "Caller's should generate a compiler problem when a default_value is missing and *not* call this method!";
        ISourceLocation assignedValueExpressionLocation = iNode.getAssignedValueNode();
        IDefinition target_type = type.getDefinition();
       
        return checkInitialValue(assignedValueExpressionLocation, target_type, initial_value);
       
    }
View Full Code Here


    /**
     * Report unexpected line terminators in a string literal.
     */
    protected final void reportInvalidLineTerminatorInStringLiteral()
    {
        final ISourceLocation location = getCurrentSourceLocation(0);
        final ICompilerProblem problem = new StringLiteralMustBeTerminatedBeforeLineBreakProblem(location);
        getProblems().add(problem);
    }
View Full Code Here

     * Report syntax error: input ended before reaching the closing quotation
     * mark for a string literal.
     */
    protected final void reportUnclosedStringLiteral()
    {
        final ISourceLocation location = getCurrentSourceLocation(0);
        final ICompilerProblem problem = new StringLiteralNotClosedProblem(location);
        getProblems().add(problem);
    }
View Full Code Here

    /**
     * Report syntax error: input ended before ASDoc is closed.
     */
    protected final void reportUnclosedASDoc()
    {
        final ISourceLocation location = getCurrentSourceLocation(0);
        final ICompilerProblem problem = new ASDocNotClosedProblem(location);
        getProblems().add(problem);
    }
View Full Code Here

    private void processFileEntry(Entry<String, FileEntryValue> entry,
                                  Collection<ICompilerProblem> problems)
    {
        String path = entry.getKey();
        IBinaryFileSpecification fileSpec = entry.getValue().getFileSpec();
        ISourceLocation sourceLocation = entry.getValue().getSourceLocation();
       
        byte[] contents = getContents(fileSpec);
       
        if (contents != null)
        {
View Full Code Here

     */
    protected abstract int getColumn();

    protected void addBadCharacterProblem(String badChar)
    {
        ISourceLocation location = getCurrentSourceLocation(badChar.length());
        ICompilerProblem problem = new BadCharacterProblem(location, badChar);
        problems.add(problem);
    }
View Full Code Here

                    break;
                }
                default:
                {
                    // Add an error if the flag is not valid.
                    ISourceLocation location = new SourceLocation(getSourcePath(),
                            getStart() + i, getStart() + i + 1, getLine(), getColumn());
                    ICompilerProblem problem = new SyntaxProblem(location, Character.toString(charAt));
                    reporter.addProblem(problem);
                    break;
                }
View Full Code Here

                                unicode = (unicode << 4) + 10 + add - 'A';
                                break;

                            default:
                            {
                                ISourceLocation location = new SourceLocation(filePath,
                                    start, start + string.length(), line, column);
                                ICompilerProblem problem = new ResourceBundleMalformedEncodingProblem(location, string);
                                problems.add(problem);
                            }
                        }
View Full Code Here

    @Override
    public ISourceFragment[] getValueFragments(Collection<ICompilerProblem> problems)
    {
        String value = getRawValue();
        ISourceLocation location = getValueLocation();
        MXMLDialect mxmlDialect = getMXMLDialect();

        String s = EntityProcessor.parseAsString(value, location, mxmlDialect, problems);
        ISourceFragment[] result = new ISourceFragment[1];
        result[0] = new SourceFragment(s, location);
View Full Code Here

        }
    }

    private static ICompilerProblem genericParserProblem(String path, int start, int end, int line, int column)
    {
        ISourceLocation location = new SourceLocation(path, start, end, line, column);
        return new ParserProblem(location);
    }
View Full Code Here

TOP

Related Classes of org.apache.flex.compiler.common.ISourceLocation

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.