Examples of IStructuredDocumentContext


Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext

        {
            return deriveIFileFromContext((IStructuredDocumentContext)context);
        }
        else
        {
            IStructuredDocumentContext  sdContext =
                (IStructuredDocumentContext) context.getAdapter(IStructuredDocumentContext.class);
           
            if (sdContext != null)
            {
                return deriveIFileFromContext(sdContext);
View Full Code Here

Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext



    private void refreshInternal(final IDOMModel model)
    {
        final IStructuredDocumentContext context =
            IStructuredDocumentContextFactory.INSTANCE.getContext(model.getStructuredDocument(), -1);
        final ITaglibContextResolver taglibResolver =
            IStructuredDocumentContextResolverFactory.INSTANCE.getTaglibContextResolver(context);
        final IDOMDocument document = model.getDocument();
        getApplicationMap().clear();
View Full Code Here

Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext

            final String symbolName = attribute.getNodeValue();

            if (factory != null)
            {
//                long curTime = System.currentTimeMillis();
                final IStructuredDocumentContext context =
                    IStructuredDocumentContextFactory.INSTANCE.
                        getContext(model.getStructuredDocument(),
                           attribute);

                if (factory.supports(context))
View Full Code Here

Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext

        .getELText(dataTableElement);
        final IFile file = FileContextUtil.deriveIFileFromContext(context);

        if (elText != null && file != null)
        {
            final IStructuredDocumentContext elContext = IStructuredDocumentContextFactory.INSTANCE
                .getContext(context.getStructuredDocument(),
                    dataTableElement.getAttributeNode("value")); //$NON-NLS-1$

            final IJavaProject javaProject = JavaCore.create(file.getProject());
View Full Code Here

Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext

            final long curTime = System.nanoTime();
            final Region2AttrAdapter attrAdapter = (Region2AttrAdapter) domAdapter;
            // check that this is attribute value region - 221722
            if (attrAdapter.getAttributeValueRegion() != null)
            {
                final IStructuredDocumentContext context = IStructuredDocumentContextFactory.INSTANCE
                .getContext(attrAdapter.getDocumentContext()
                        .getStructuredDocument(), attrAdapter
                        .getOwningElement().getDocumentContext()
                        .getDocumentPosition()
                        + attrAdapter.getAttributeValueRegion()
View Full Code Here

Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext

                // use the attribute's context plus the offset into the
                // whole attribute value to find where we think the el
                // expression starts. Add one since the attribute value
                // string returned by attrAdapter will have the value quotes
                // removed, but the region offsets include the quotes.
                IStructuredDocumentContext elContext = IStructuredDocumentContextFactory.INSTANCE
                .getContext(context.getStructuredDocument(), context
                        .getDocumentPosition()
                        + offsetOfFirstEL + 1);
                final DTELExpression elExpression = adapter
                .getELExpression(elContext);
                if (elExpression != null)
                {
                    final String elText = elExpression.getText();

                    if (DEBUG)
                    {
                        System.out.println(addDebugSpacer(3) + "EL attrVal= " //$NON-NLS-1$
                                + elText);
                    }

                    elContext = elExpression.getDocumentContext();
                    // EL validation is user configurable because
                    // it can be computationally costly.
                    if (_validationContext.shouldValidateEL())
                    {
                        // also, skip the validation if the expression is empty
                        // or only whitespace, since the parser doesn't handle
                        // it
                        // anyway.
                        if ("".equals(elText.trim())) //$NON-NLS-1$
                        {
                            final int offset = elContext.getDocumentPosition() - 1;
                            final int length = elText.length() + 2;
                            final Diagnostic diagnostic = _validationContext
                            .getDiagnosticFactory()
                            .create_EMPTY_EL_EXPRESSION();
                            // detected empty EL expression
View Full Code Here

Examples of org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext

        if (disableAlternativeTypes())
        {
            return expectedType;
        }

        final IStructuredDocumentContext context = elementAdapter
                .getDocumentContext();
        final DTUIViewRoot viewRoot = _validationContext.getViewRootHandle().getCachedViewRoot();
        final IAdaptable serviceAdaptable = viewRoot.getServices();
        final XMLViewObjectMappingService mappingService = (XMLViewObjectMappingService) serviceAdaptable
                .getAdapter(XMLViewObjectMappingService.class);
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.