Package com.volantis.mcs.protocols.widgets

Examples of com.volantis.mcs.protocols.widgets.WidgetModule


    protected WidgetRenderer getWidgetRenderer(XDIMEContextInternal context)
        throws ProtocolException {
       
        // First get the widget module, which is a part of protocol
        // responsible for rendering widgets
        WidgetModule widgetModule =  getWidgetModule(context);
       
        // No renderer if no module
        if (null == widgetModule){
            return null;
        }

        // Get renderer for this particular widget
        return widgetModule.getWidgetRenderer(protocolAttributes);
    }
View Full Code Here


    // Javadoc inherited
    public XDIMEResult callOpenOnProtocol(XDIMEContextInternal context, XDIMEAttributes attributes)
    throws XDIMEException {
       
        WidgetModule widgetModule =  getWidgetModule(context);       
        // Do nothing if widgets are not supported at all
        if (null == widgetModule){
            return XDIMEResult.SKIP_ELEMENT_BODY;      
        }
                       
        try {       
            WizardRenderer wizardRenderer = widgetModule.getWizardRenderer();
            if (null == wizardRenderer){
                return XDIMEResult.SKIP_ELEMENT_BODY;      
            }           
            wizardRenderer.renderOpen(getProtocol(context), (WidgetAttributes)protocolAttributes);           
        } catch (ProtocolException e) {
View Full Code Here

    public XDIMEResult callOpenOnProtocol(XDIMEContextInternal context,
            XDIMEAttributes attributes) throws XDIMEException {

        try {
            WidgetModule widgetModule = getWidgetModule(context);
            // Do nothing if widgets are not supported at all
            if (null == widgetModule) {
                // Do fallback if widget is not supported by the protocol
                return doFallbackOpen(context, attributes);
            }
           
            TabsRenderer tabsRenderer = widgetModule.getTabsRenderer();
            if (null == tabsRenderer) {
                // Do fallback if widget is not supported by the protocol
                return doFallbackOpen(context, attributes);       
            }
            // Open tab element
View Full Code Here

    }

    public void callCloseOnProtocol(XDIMEContextInternal context)
            throws XDIMEException {

        WidgetModule widgetModule = getWidgetModule(context);
        // Do nothing if widgets are not supported at all
        if (null == widgetModule) {
            // Do fallback if widget is not supported by the protocol
            doFallbackClose(context);
            return;
        }

        try {
            TabsRenderer tabsRenderer = widgetModule.getTabsRenderer();
            if (null == tabsRenderer) {
                // Do fallback if widget is not supported by the protocol
                doFallbackClose(context);
                return;
            }
View Full Code Here

    public XDIMEResult callOpenOnProtocol(
            XDIMEContextInternal context, XDIMEAttributes attributes)
            throws XDIMEException {

        try {
            WidgetModule widgetModule = getWidgetModule(context);
            // Do nothing if widgets are not supported at all
            if (null == widgetModule) {
                // Do fallback if widget is not supported by the protocol
                return doFallbackOpen(context, attributes);
            }

            TabsRenderer tabsRenderer = widgetModule.getTabsRenderer();
            if (null == tabsRenderer){
                // Do fallback if widget is not supported by the protocol
                return doFallbackOpen(context, attributes);       
            }
            // Send page context to the renderer via attributes.
View Full Code Here

    }
   
    public void callCloseOnProtocol(XDIMEContextInternal context)
            throws XDIMEException {
       
        WidgetModule widgetModule =  getWidgetModule(context);       
        // Do nothing if widgets are not supported at all
        if (null == widgetModule){
            // Do fallback if widget is not supported by the protocol
            doFallbackClose(context);
            return;      
        }

        try {       
            TabsRenderer tabsRenderer = widgetModule.getTabsRenderer();
            if (null == tabsRenderer) {
                // Do fallback if widget is not supported by the protocol
                doFallbackClose(context);
                return;
            }                                   
View Full Code Here

    // Javadoc inherited
    protected void initialiseElementSpecificAttributes(
            XDIMEContextInternal context, XDIMEAttributes attributes)
            throws XDIMEException {
       
        WidgetModule widgetModule =  getWidgetModule(context);
       
        // Skip initialisation if vakidator widget is not supported
        if (null == widgetModule){
            return;
        }
        try {
            WidgetRenderer renderer = widgetModule.getValidateRenderer();
            if (null == renderer || !renderer.isWidgetSupported(getProtocol(context))) {
                return;
            }              
        } catch (ProtocolException e) {
            throw new XDIMEException(e);
View Full Code Here

        // directly inside the containing list element which is invalid.
        boolean shouldRenderBody = false;
       
        if (isDynamicMenu(parent, protocol)) {

            WidgetModule widgetModule = protocol.getWidgetModule();
            if (null == widgetModule) {
                return XDIMEResult.SKIP_ELEMENT_BODY;
            }

            try {
                DynamicMenuWidgetRenderer dynamicMenuRenderer
                    = widgetModule.getDynamicMenuRenderer();
               
                if (null == dynamicMenuRenderer) {
                    return XDIMEResult.SKIP_ELEMENT_BODY;
                }                   
                shouldRenderBody = dynamicMenuRenderer.renderLabelOpen(
View Full Code Here

            throws XDIMEException {

        VolantisProtocol protocol = getProtocol(context);

        if (isDynamicMenu(context.getCurrentElement(), protocol)) {
            WidgetModule widgetModule = protocol.getWidgetModule();
            // Do nothing if widgets are not supported at all
            if (null == widgetModule) {
                return;
            }
           
            try {
                DynamicMenuWidgetRenderer dynamicMenuRenderer
                    = widgetModule.getDynamicMenuRenderer();
               
                if (null == dynamicMenuRenderer) {
                    return;
                }
                // render label as dynamic menu item which has submenu
View Full Code Here

        boolean shouldRenderContent = isWidgetSupported(protocol);
       
        // If it should, check if the content for the popup should be rendered.
        if (shouldRenderContent) {
            try {
                WidgetModule module = getWidgetDefaultModule(protocol);
               
                if (module != null) {
                    WidgetRenderer popupRenderer = module.getPopupRenderer();
                   
                    if (popupRenderer != null) {
                        shouldRenderContent = popupRenderer.shouldRenderContents(protocol, popupAttributes);
                    }
                }
View Full Code Here

TOP

Related Classes of com.volantis.mcs.protocols.widgets.WidgetModule

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.