Package org.jboss.dashboard.domain

Examples of org.jboss.dashboard.domain.Domain


                    else adp.getNameI18nMap().remove(new Locale(lang));
                }
                if (param_name.startsWith(PARAM_PROPERTY_TYPE)) {
                    String pId = param_name.substring(param_name.indexOf("_") + 1, param_name.length());
                    AbstractDataProperty adp = (AbstractDataProperty) dataProvider.getDataSet().getPropertyById(pId);
                    Domain domnain = (Domain) Class.forName(param_value).newInstance();
                    if (domnain instanceof LabelDomain) ((LabelDomain) domnain).setConvertedFromNumeric(true);
                    adp.setDomain(domnain);
                }
            }
            dataProvider.save();
View Full Code Here


            DataProperty[] properties = newDataSetConfigured.getProperties();
            for (int i = 0; i < properties.length; i++) {
                DataProperty configuredProperty = properties[i];
                DataProperty notConfiguredProperty = newDataSetNotConfigured.getPropertyById(configuredProperty.getPropertyId());

                Domain oldDomain = configuredProperty.getDomain();
                if (!(oldDomain instanceof LabelDomain && ((LabelDomain) oldDomain).isConvertedFromNumeric())) {
                    configuredProperty.setDomain(notConfiguredProperty.getDomain());
                }
            }
View Full Code Here

                    setAttribute("index", new Integer(i));
                    renderFragment("outputStartRow");
                    setAttribute("propertyId", property.getPropertyId());
                    renderFragment("outputPropertyId");

                    Domain domain = property.getDomain();
                    String domainI18nKey = "";
                    if (domain instanceof NumericDomain) domainI18nKey = "numeric";
                    else if (domain instanceof LabelDomain) domainI18nKey = "label";
                    else if (domain instanceof DateDomain) domainI18nKey = "date";
View Full Code Here

                    else adp.getNameI18nMap().remove(new Locale(lang));
                }
                if (param_name.startsWith(PARAM_PROPERTY_TYPE)) {
                    String pId = param_name.substring(param_name.indexOf("_") + 1, param_name.length());
                    AbstractDataProperty adp = (AbstractDataProperty) dataProvider.getDataSet().getPropertyById(pId);
                    Domain domnain = (Domain) Class.forName(param_value).newInstance();
                    if (domnain instanceof LabelDomain) ((LabelDomain) domnain).setConvertedFromNumeric(true);
                    adp.setDomain(domnain);
                }
            }
            dataProvider.save();
View Full Code Here

                    setAttribute("index", new Integer(i));
                    renderFragment("outputStartRow");
                    setAttribute("propertyId", property.getPropertyId());
                    renderFragment("outputPropertyId");

                    Domain domain = property.getDomain();
                    String domainI18nKey = "";
                    if (domain instanceof NumericDomain) domainI18nKey = "numeric";
                    else if (domain instanceof LabelDomain) domainI18nKey = "label";
                    else if (domain instanceof DateDomain) domainI18nKey = "date";
View Full Code Here

        for (int i = 0; i < properties.length; i++) {
            DataProperty property = properties[i];
            printIndent(out, indent++);
            out.println("<dataproperty id=\"" + StringEscapeUtils.escapeXml(property.getPropertyId()) + "\">");
            printIndent(out, indent);
            Domain domain = property.getDomain();
            String convertedFromNumeric = "";
            if (domain instanceof LabelDomain && ((LabelDomain)domain).isConvertedFromNumeric()) convertedFromNumeric = " convertedFromNumeric=\"true\" ";
            out.println("<domain" + convertedFromNumeric + ">" + StringEscapeUtils.escapeXml(property.getDomain().getClass().getName()) + "</domain>");
            Map names = property.getNameI18nMap();
            if (names != null) {
View Full Code Here

                NodeList dataProperties = node.getChildNodes();
                for (int y = 0; y < dataProperties.getLength(); y++) {
                    Node dataProperty = dataProperties.item(y);
                    if (dataProperty.getNodeName().equals("domain")) {
                        Domain domain = (Domain) Class.forName(StringEscapeUtils.unescapeXml(dataProperty.getFirstChild().getNodeValue())).newInstance();
                        if (dataProperty.getAttributes().getNamedItem("convertedFromNumeric") != null) ((LabelDomain) domain).setConvertedFromNumeric(true);
                        property.setDomain(domain);
                    }
                    if (dataProperty.getNodeName().equals("name")) {
                        String lang = dataProperty.getAttributes().getNamedItem("language").getNodeValue();
View Full Code Here

                    else adp.getNameI18nMap().remove(new Locale(lang));
                }
                if (param_name.startsWith(PARAM_PROPERTY_TYPE)) {
                    String pId = param_name.substring(param_name.indexOf("_") + 1, param_name.length());
                    AbstractDataProperty adp = (AbstractDataProperty) dataProvider.getDataSet().getPropertyById(pId);
                    Domain domnain = (Domain) Class.forName(param_value).newInstance();
                    if (domnain instanceof LabelDomain) ((LabelDomain) domnain).setConvertedFromNumeric(true);
                    adp.setDomain(domnain);
                }
            }
            dataProvider.save();
View Full Code Here

            DataProperty[] properties = newDataSetConfigured.getProperties();
            for (int i = 0; i < properties.length; i++) {
                DataProperty configuredProperty = properties[i];
                DataProperty notConfiguredProperty = newDataSetNotConfigured.getPropertyById(configuredProperty.getPropertyId());

                Domain oldDomain = configuredProperty.getDomain();
                if (!(oldDomain instanceof LabelDomain && ((LabelDomain) oldDomain).isConvertedFromNumeric())) {
                    configuredProperty.setDomain(notConfiguredProperty.getDomain());
                }
            }
View Full Code Here

                    setAttribute("index", new Integer(i));
                    renderFragment("outputStartRow");
                    setAttribute("propertyId", property.getPropertyId());
                    renderFragment("outputPropertyId");

                    Domain domain = property.getDomain();
                    String domainI18nKey = "";
                    if (domain instanceof NumericDomain) domainI18nKey = "numeric";
                    else if (domain instanceof LabelDomain) domainI18nKey = "label";
                    else if (domain instanceof DateDomain) domainI18nKey = "date";
View Full Code Here

TOP

Related Classes of org.jboss.dashboard.domain.Domain

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.