Package com.volantis.mcs.devices.policy.types

Examples of com.volantis.mcs.devices.policy.types.RangePolicyType


                    connection, "RangesPolicy", locale);
            policyType = policyDescriptor.getPolicyType();
            assertNotNull("Policy Descriptor should be found", policyDescriptor);
            assertTrue("Type should match: " + policyType,
                    policyType instanceof RangePolicyType);
            RangePolicyType rangeType =
                    (RangePolicyType)policyType;

            assertEquals("Selections size should match", 77,
                    rangeType.getMinInclusive());
            assertEquals("Selections size should match", 188,
                    rangeType.getMaxInclusive());

            // Test the retrieval of a policy descriptor from VMTYPES_STRUCTURE
            id = populateWithStructure(id);
            policyDescriptor = accessor.retrievePolicyDescriptor(
                    connection, "StructurePolicy", locale);
View Full Code Here


        } else if (policyType instanceof StructurePolicyType) {
            StructurePolicyType structure = (StructurePolicyType) policyType;
            addTypeInstanceStructure(connection, typeInstanceId,
                    structure);
        } else if (policyType instanceof RangePolicyType) {
            RangePolicyType range = (RangePolicyType) policyType;
            insertTypeInstanceRange(connection, typeInstanceId,
                    range.getMinInclusive(), range.getMaxInclusive());
        } else if (policyType instanceof SelectionPolicyType) {
            SelectionPolicyType selection = (SelectionPolicyType) policyType;
            insertTypeInstanceSelection(connection, typeInstanceId,
                    selection.getKeywords());
        }
View Full Code Here

                        " device for securing user data");
                assertEquals("Category should match (range)",
                        descriptor.getCategoryName(),
                        "security");
                // Ensure the type is of the correct type (try a cast!)
                RangePolicyType rangeType = (RangePolicyType) descriptor.getPolicyType();
                assertEquals("Max should match", 100, rangeType.getMaxInclusive());
                assertEquals("Min should match", -1, rangeType.getMinInclusive());

                // ------------------------------------------------------------
                // selection
                // ------------------------------------------------------------
                descriptor = (DefaultPolicyDescriptor)
View Full Code Here

TOP

Related Classes of com.volantis.mcs.devices.policy.types.RangePolicyType

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.