Package org.eclipse.jst.jsf.designtime.internal.view

Examples of org.eclipse.jst.jsf.designtime.internal.view.IDTViewHandler


     * @return true if file has a design time faces context
     */
    public boolean hasDTFacesContext(final IFile file)
    {
        checkIsDisposed();
        final IDTViewHandler viewHandler = getViewHandler();

        if (file != null && file.isAccessible() && viewHandler != null
                && viewHandler.supportsViewDefinition(file))
        {
            return true;
        }
        return false;
    }
View Full Code Here


        if (manager == null)
        {
            return null;
        }
        final IDTViewHandler viewHandler =
                DesignTimeApplicationManager.getInstance(project)
                        .getViewHandler();
        try
        {
            final DTFacesContext facesContext = manager.getFacesContext(file);
           
            if (facesContext != null)
            {
                final IViewDefnAdapterFactory factory =
                        viewHandler.getViewMetadataAdapterFactory(facesContext);
                final IViewDefnAdapter adapter =
                        factory.createAdapter(facesContext, viewHandler.getViewId(
                                facesContext, file));
   
                if (adapter instanceof XMLViewDefnAdapter)
                {
                    return (XMLViewDefnAdapter) adapter;
View Full Code Here

            if (viewRoot == null || viewRoot.isStale())
            {
                // if the view root hasn't been created, then do so
                // and populate it
                final IDTViewHandler viewHandler = _facesContext
                        .getViewHandler(contextResource);

                if (viewHandler != null)
                {
                    final String viewId = viewHandler.getViewId(
                            _facesContext, contextResource);

                    try
                    {
                        viewRoot = viewHandler.createView(_facesContext,
                                viewId);
                        if (viewRoot != null)
                        {
                            setCachedViewRoot(viewRoot);
                        }
View Full Code Here

        return null;
    }

    IDTViewHandler getViewHandler(final IResource res)
    {
        IDTViewHandler viewHandler = null;

        if (res != null)
        {
            final DesignTimeApplicationManager manager = DesignTimeApplicationManager
                    .getInstance(res.getProject());
View Full Code Here

        final ValidationPreferences prefs = new ValidationPreferences(
                JSFCorePlugin.getDefault().getPreferenceStore());
        prefs.load();
        final DiagnosticFactory diagnosticFactory = new DiagnosticFactory();

        final IDTViewHandler viewHandler = DTAppManagerUtil.getViewHandler(file
                .getProject());

        // only validate files that our designtime supports
        if (viewHandler == null || !viewHandler.supportsViewDefinition(file))
        {
            return null;
        }

        return new JSFValidationContext(isIncremental, prefs, viewHandler,
View Full Code Here

TOP

Related Classes of org.eclipse.jst.jsf.designtime.internal.view.IDTViewHandler

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.