Examples of convertFromString()


Examples of org.apache.cocoon.woody.datatype.convertor.Convertor.convertFromString()

                Object value;
                if ("".equals(stringValue)) {
                    // Empty value translates into the null object
                    value = null;
                } else {
                    value = convertor.convertFromString(stringValue, Locale.US, formatCache);
                    if (value == null) {
                        throw new Exception("Could not convert the value \"" + stringValue +
                                            "\" to the type " + datatype.getDescriptiveName() +
                                            ", defined at " + DomHelper.getLocation(element));
                    }
View Full Code Here

Examples of org.apache.cocoon.woody.datatype.convertor.Convertor.convertFromString()

                Object value;
                if ("".equals(stringValue)) {
                    // Empty value translates into the null object
                    value = null;
                } else {
                    value = convertor.convertFromString(stringValue, Locale.US, formatCache);
                    if (value == null) {
                        throw new Exception("Could not convert the value \"" + stringValue +
                                            "\" to the type " + datatype.getDescriptiveName() +
                                            ", defined at " + DomHelper.getLocation(element));
                    }
View Full Code Here

Examples of org.apache.cocoon.woody.datatype.convertor.Convertor.convertFromString()

                if (convertor == null) {
                    convertor = datatype.getConvertor();
                }
                Element element = (Element)node;
                String stringValue = element.getAttribute("value");
                Object value = convertor.convertFromString(stringValue, Locale.US, formatCache);
                if (value == null)
                    throw new Exception("Could not convert the value \"" + stringValue + "\" to the type " + datatype.getDescriptiveName() + ", defined at " + DomHelper.getLocation(element));

                Object label = null;
                Element labelEl = DomHelper.getChildElement(element, Constants.WD_NS, "label");
View Full Code Here

Examples of org.openbp.core.model.item.type.DataTypeItem.convertFromString()

        {
          if (value instanceof String)
          {
            // Try to convert the string representation to the type
            // we expect for this parameter
            value = type.convertFromString((String) value, null, null);
          }
          else
          {
            // Check if the value type matches the parameter type;
            // otherwise the application programmer obviously supplied the wrong type of data in the input parameters.
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.