Examples of DatatypeConverterImpl


Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

public class DefaultValueTest extends TestCase {

    public void testFooDefaultValues() throws Exception {

        DatatypeConverter.setDatatypeConverter(new DatatypeConverterImpl());
       
        Foo foo = new org.apache.cxf.configuration.foo.ObjectFactory().createFoo();

        // verify default values
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

      "<ex:DurationElem>P1Y2M3DT4H5M6.7S</ex:DurationElem>" +
      "<ex:HexBinaryElem>0111234E739DBBFF</ex:HexBinaryElem>" +
      "<ex:Base64BinaryElem>AREjTnOdu/8=</ex:Base64BinaryElem>" +
      "<ex:NmTokenElem>a-name-token</ex:NmTokenElem>" +
      "<ex:NmTokensElem>a-name-token another:name-token</ex:NmTokensElem>" +
      "<ex:DecimalElem>" + new DatatypeConverterImpl().printDecimal(newBigDecimal()) + "</ex:DecimalElem>" +
      "<ex:IntegerElem>-602300000000000000000000</ex:IntegerElem>" +
      "<ex:NonNegativeIntegerElem>101</ex:NonNegativeIntegerElem>" +
      "<ex:PositiveIntegerElem>602300000000000000000000</ex:PositiveIntegerElem>" +
      "<ex:NonPositiveIntegerElem>-21714</ex:NonPositiveIntegerElem>" +
      "<ex:NegativeIntegerElem>-21714</ex:NegativeIntegerElem>" +
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

      sep2 + "<ex:DurationElem>P1Y2M3DT4H5M6.7S</ex:DurationElem>" + lf +
      sep2 + "<ex:HexBinaryElem>0111234E739DBBFF</ex:HexBinaryElem>" + lf +
      sep2 + "<ex:Base64BinaryElem>AREjTnOdu/8=</ex:Base64BinaryElem>" + lf +
      sep2 + "<ex:NmTokenElem>a-name-token</ex:NmTokenElem>" + lf +
      sep2 + "<ex:NmTokensElem>a-name-token another:name-token</ex:NmTokensElem>" + lf +
      sep2 + "<ex:DecimalElem>" + new DatatypeConverterImpl().printDecimal(newBigDecimal()) + "</ex:DecimalElem>" + lf +
      sep2 + "<ex:IntegerElem>-602300000000000000000000</ex:IntegerElem>" + lf +
      sep2 + "<ex:NonNegativeIntegerElem>101</ex:NonNegativeIntegerElem>" + lf +
      sep2 + "<ex:PositiveIntegerElem>602300000000000000000000</ex:PositiveIntegerElem>" + lf +
      sep2 + "<ex:NonPositiveIntegerElem>-21714</ex:NonPositiveIntegerElem>" + lf +
      sep2 + "<ex:NegativeIntegerElem>-21714</ex:NegativeIntegerElem>" + lf +
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

      "<ex:DurationElem>P1Y2M3DT4H5M6.7S</ex:DurationElem>",
      "<ex:HexBinaryElem>0111234E739DBBFF</ex:HexBinaryElem>",
      "<ex:Base64BinaryElem>AREjTnOdu/8=</ex:Base64BinaryElem>",
      "<ex:NmTokenElem>a-name-token</ex:NmTokenElem>",
      "<ex:NmTokensElem>a-name-token another:name-token</ex:NmTokensElem>",
      "<ex:DecimalElem>" + new DatatypeConverterImpl().printDecimal(newBigDecimal()) + "</ex:DecimalElem>",
      "<ex:IntegerElem>-602300000000000000000000</ex:IntegerElem>",
      "<ex:NonNegativeIntegerElem>101</ex:NonNegativeIntegerElem>",
      "<ex:PositiveIntegerElem>602300000000000000000000</ex:PositiveIntegerElem>",
      "<ex:NonPositiveIntegerElem>-21714</ex:NonPositiveIntegerElem>",
      "<ex:NegativeIntegerElem>-21714</ex:NegativeIntegerElem>",
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

public class ConfigurableBeansPluginTest extends TestCase {

    public void testFooDefaultValues() throws Exception {

        DatatypeConverter.setDatatypeConverter(new DatatypeConverterImpl());
       
        Foo foo = new org.apache.cxf.configuration.foo.ObjectFactory().createFoo();
       
        assertTrue("Foo should inhertit from AbstractConfigurableBeanBase",
                   foo instanceof AbstractConfigurableBeanBase);
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

        assertDefaultAttributeValues(foo);       
        assertDefaultElementValues(foo);     
    }
   
    public void testProviders() {
        DatatypeConverter.setDatatypeConverter(new DatatypeConverterImpl());
        Foo foo = new org.apache.cxf.configuration.foo.ObjectFactory().createFoo();
        ConfigurationProvider provider = new ConfigurationProvider() {

            public Object getObject(String name) {
                if ("integerAttr".equals(name) || "integerAttrNoDefault".equals(name)) {
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

        assertEquals(BigInteger.TEN, foo.getIntegerAttrNoDefault());
        assertEquals(BigInteger.TEN, foo.getIntegerAttr());      
    }
   
    public void testNotifyPropertyChange() {
        DatatypeConverter.setDatatypeConverter(new DatatypeConverterImpl());
        FooBean foo = new FooBean();
       
        assertNull(foo.getIntegerAttrNoDefault());
        assertEquals(new BigInteger("11"), foo.getIntegerElem());
        assertNull(foo.getChangedProperty());
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

public class JaxbPropertyEditorTest extends TestCase {

    public void testPerType() throws Exception {
       
        DatatypeConverter.setDatatypeConverter(new DatatypeConverterImpl());
       
        JaxbClassPathXmlApplicationContext context = new JaxbClassPathXmlApplicationContext(new String[] {
            "/org/apache/cxf/configuration/spring/test-jaxb-beans.xml",
            "/org/apache/cxf/configuration/spring/cxf-property-editors.xml"
        });
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

        assertEquals("Unexpected value for name", "foam", foo.getName())
    }
   
    public void testPerPackage() throws Exception {
       
        DatatypeConverter.setDatatypeConverter(new DatatypeConverterImpl());
       
        JaxbClassPathXmlApplicationContext context = new JaxbClassPathXmlApplicationContext(new String[] {
            "/org/apache/cxf/configuration/spring/test-jaxb-beans.xml",
            "/org/apache/cxf/configuration/spring/cxf.xml",
            "/org/apache/cxf/configuration/spring/cxf-jaxb-property-types.xml",
View Full Code Here

Examples of org.apache.ws.jaxme.impl.DatatypeConverterImpl

  protected String getDatatypeName() { return "Float"; }
  protected JavaQName getDatatypeType() { return FLOAT_TYPE; }

  public TypedValue getCastFromString(SimpleTypeSG pController, String pValue) throws SAXException {
    try {
      return new TypedValueImpl(new Float(new DatatypeConverterImpl().parseFloat(pValue)) + "f", FLOAT_TYPE);
  } catch (RuntimeException e) {
    try {
      throw new LocSAXException("Failed to convert string value to "
          + getDatatypeName() + " instance: " + pValue, getLocator());
    } catch (Exception e1) {
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.