Examples of VariantType


Examples of com.volantis.mcs.policies.variants.VariantType

        BeanProxy selectedVariant = context.getSelectedVariant();
        Proxy variantType = selectedVariant.getPropertyProxy(PolicyModel.VARIANT_TYPE);
        if (nullCheckbox.getSelection()) {
            variantType.setModelObject(VariantType.NULL);
        } else {
            VariantType defaultType = context.getDefaultVariantType();
            variantType.setModelObject(defaultType);
        }
    }
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

     *
     * @param selectedVariant to display the contents of
     */
    private void setDisplayContent(BeanProxy selectedVariant) {

        VariantType type =
            (VariantType)selectedVariant.
                getPropertyProxy(PolicyModel.VARIANT_TYPE).getModelObject();

        ContentBuilder content =
            (ContentBuilder) selectedVariant.
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

            public void run() {
                BeanProxy theme = (BeanProxy) context.getInteractionModel();
                ListProxy variants = (ListProxy)
                        theme.getPropertyProxy(PolicyModel.VARIANTS);

                final VariantType variantType =
                    ((PolicyEditorContext) context).getDefaultVariantType();
                VariantBuilder newVariant = PolicyFactory.getDefaultInstance().
                        createVariantBuilder(variantType);
                if (variantType == VariantType.THEME) {
                    final ThemeContentBuilder contentBuilder =
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

    public Action createNewVariantAction(final EditorContext context, final Control control) {
        Action newAction = new Action() {
            public void run() {
                BeanProxy interactionModel = (BeanProxy) context.getInteractionModel();
                ListProxy variantsModel = (ListProxy) interactionModel.getPropertyProxy(PolicyModel.VARIANTS);
                VariantType type = ((PolicyEditorContext) context).getDefaultVariantType();
                NewVariantWizard wizard = NewVariantWizard.createNewVariantWizard(type, variantsModel, context);
                wizard.init(null, null);
                // Instantiates the wizard container with the wizard and opens it
                WizardDialog dialog = new WizardDialog(control.getShell(), wizard);
                dialog.create();
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

        table.setSize(table.getSize().x, tableMinHeight);

        viewer = new TableViewer(table);
        viewer.setContentProvider(new ListProxyContentProvider());

        VariantType defaultVariantType =
                ((PolicyEditorContext) context).getDefaultVariantType();

        VariantProxyLabelProvider provider = new VariantProxyLabelProvider(
                defaultVariantType);
        ProxyLabelDecorator decorator = new ProxyLabelDecorator();
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

        if (diagnostics != null && !diagnostics.isEmpty()) {
         
            Object model = proxy.getModelObject();
            if (model != null && model instanceof VariantBuilder) {
                VariantBuilder variant = (VariantBuilder) model;
                VariantType type = variant.getVariantType();

                if (type == VariantType.LAYOUT) {
                    InternalLayoutContentBuilder content =
                            (InternalLayoutContentBuilder)
                            variant.getContentBuilder();
                    if (content != null) {
                        Layout layout = content.getLayout();
                        if (layout != null) {
                            key = layout.getType().toString();
                        }
                    }
                } else {
                    key = type.toString();
                }
            }

          Image cachedImage = null;
          if((cachedImage = registry.get("ERROR_IMAGE_" + key)) != null) {
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

        if (!proxy.isReadOnly()) {
         
            Object model = proxy.getModelObject();
            if (model != null && model instanceof VariantBuilder) {
                VariantBuilder variant = (VariantBuilder) model;
                VariantType type = variant.getVariantType();

                if (type == VariantType.LAYOUT) {
                    InternalLayoutContentBuilder content =
                            (InternalLayoutContentBuilder)
                            variant.getContentBuilder();
                    if (content != null) {
                        Layout layout = content.getLayout();
                        if (layout != null) {
                            key = layout.getType().toString();
                        }
                    }
                } else {
                    key = type.toString();
                }
            }         
                                     
          Image cachedImage = null;
          if((cachedImage = registry.get("LOCKED_IMAGE_" + key)) != null) {
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

        if (o != null) {
            Proxy proxy = (Proxy) o;
            Object model = proxy.getModelObject();
            if (model != null && model instanceof VariantBuilder) {
                VariantBuilder variant = (VariantBuilder) model;
                VariantType type = variant.getVariantType();

                if (type == VariantType.LAYOUT) {
                    InternalLayoutContentBuilder content =
                            (InternalLayoutContentBuilder)
                            variant.getContentBuilder();
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

        builder.setGeneratedResourceBaseDir(generatedResourceBaseDir);
        builder.setAssetsBaseURL(baseURL);
        builder.setCacheControlDefaultsMap(cacheControlConstraintsMap);
        for (Iterator i = variantType2PrefixURL.entrySet().iterator(); i.hasNext();) {
            Map.Entry entry = (Map.Entry) i.next();
            VariantType variantType = (VariantType) entry.getKey();
            MarinerURL prefixURL = (MarinerURL) entry.getValue();
            builder.addVariantPrefixURL(variantType, prefixURL);
        }
        return builder.getProject();
    }
View Full Code Here

Examples of com.volantis.mcs.policies.variants.VariantType

        // The external link rendered for device independent resource will have
        // correct URL if used device support encoding from selected variant
        // otherwise returned variant will be null because selected variant is
        // filtered by PolicyVariantSelector#filter method       
        Variant variant = selectedVariant.getVariant();
        VariantType variantType = null;

        if(variant != null) {
            variantType = variant.getVariantType();
        }
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.