Package com.volantis.mcs.policies.variants.selection

Examples of com.volantis.mcs.policies.variants.selection.TargetedSelectionBuilder


        Iterator it = variants.iterator();
        while (it.hasNext()) {
            VariantBuilder variant = (VariantBuilder) it.next();
            SelectionBuilder selection = variant.getSelectionBuilder();
            if (selection instanceof TargetedSelectionBuilder) {
                TargetedSelectionBuilder targeted = (TargetedSelectionBuilder) selection;
                List categoryReferences = targeted.getModifiableCategoryReferences();
                List deviceReferences = targeted.getModifiableDeviceReferences();

                Iterator newTargets = selector.getSelectedTargets().iterator();
                while (newTargets.hasNext()) {
                    Object target = newTargets.next();
                    if (target instanceof CategoryReference) {
View Full Code Here


            setGenericSectionEnabled(false);
            criteriaCombo.setSelection(StructuredSelection.EMPTY);
        } else if (supportsTargetedSelection &&
                selection instanceof TargetedSelectionBuilder) {
            criteriaCombo.setSelection(new StructuredSelection(TargetedSelectionBuilder.class));
            TargetedSelectionBuilder targetted = (TargetedSelectionBuilder) selection;
            targets.clear();
            List categoryReferences = targetted.getModifiableCategoryReferences();
            List deviceReferences = targetted.getModifiableDeviceReferences();
            targets.addAll(categoryReferences);
            targets.addAll(deviceReferences);
            targetViewer.refresh();
            setTargetSectionEnabled(true);
            setGenericSectionEnabled(false);
View Full Code Here

            String assetGroup, String deviceName) throws IOException {

        VariantBuilder variantBuilder =
                factory.createVariantBuilder(VariantType.IMAGE);

        TargetedSelectionBuilder targeted =
                factory.createTargetedSelectionBuilder();
        targeted.addDevice(deviceName);
        variantBuilder.setSelectionBuilder(targeted);

        ImageMetaDataBuilder image = createImageMetaData(imageFile);
        variantBuilder.setMetaDataBuilder(image);
View Full Code Here

        VariantBuilder variantBuilder =
                factory.createVariantBuilder(VariantType.IMAGE);
        policyBuilder.addVariantBuilder(variantBuilder);

        // Selection.
        TargetedSelectionBuilder targeted =
                factory.createTargetedSelectionBuilder();
        targeted.addDevice("PC");
        targeted.addDevice("Master");

        variantBuilder.setSelectionBuilder(targeted);

        // Meta Data.
        ImageMetaDataBuilder imageBuilder =
View Full Code Here

        VariantBuilder variantBuilder =
                factory.createVariantBuilder(VariantType.IMAGE);
        policyBuilder.addVariantBuilder(variantBuilder);

        // Selection.
        TargetedSelectionBuilder targeted =
                factory.createTargetedSelectionBuilder();
        targeted.addCategory("Ok");
        targeted.addCategory("Good");

        variantBuilder.setSelectionBuilder(targeted);

        // Meta Data.
        ImageMetaDataBuilder imageBuilder =
View Full Code Here

TOP

Related Classes of com.volantis.mcs.policies.variants.selection.TargetedSelectionBuilder

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.