Package com.volantis.mcs.build.themes.definitions

Examples of com.volantis.mcs.build.themes.definitions.PropertyReference


        } else if (name.equals("listType") ||
                name.equals("orderedSetType")) {
            processThemePropertyChildren(element);
        } else if (name.equals("propertyRef")) {
            // This only works inside initialValue.
            PropertyReference reference = (PropertyReference)
                    findObject(PropertyReference.class);
            String propertyName = element.getText();
            if (reference == null) {
                System.out.println("Ignoring reference to property '" +
                                   propertyName + "'");
            } else {
                reference.setPropertyName(propertyName);
            }
        } else if (name.equals("computedRef")) {
            // This only works inside initialValue.
            ComputedReference reference = (ComputedReference)
                findObject(ComputedReference.class);
            if (reference == null) {
                System.out.println("Ignoring reference to computedRef");
            } else {

                Named propertyName = definitionsFactory.createProperty();
                pushObject(propertyName);
                Rules rules = definitionsFactory.createRules();
                pushObject(rules);
                processThemePropertyChildren(element);
                popObject();
                popObject();

                reference.setPropertyName(propertyName.getName());
                reference.setRules(rules.getRuleSet());
            }

        } else if (name.equals("rule")) {

            Rules ruleSet = (Rules) findObject(Rules.class);
View Full Code Here


        // Create a container to hold the initial value.
        SingleValueContainer container = new SingleValueContainer();
        pushObject(container);

        // Create a container for a property reference.
        PropertyReference reference = new PropertyReference();
        pushObject(reference);

        // Create a container for a computed reference.
        ComputedReference computedRef = new ComputedReference();
        pushObject(computedRef);

        // Process the children.
        processThemePropertyChildren(element);

        popObject();
        popObject();
        popObject();

        String computedPropertyRef = computedRef.getPropertyName();
        String propertyReference = reference.getPropertyName();
        Value initialValue = container.getValue();

        if ((propertyReference != null   && initialValue != null) ||
            (propertyReference != null   && computedPropertyRef != null) ||
            (computedPropertyRef != null && initialValue != null)) {
View Full Code Here

TOP

Related Classes of com.volantis.mcs.build.themes.definitions.PropertyReference

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.