Code example for DatatypeFactory

Methods: newXMLGregorianCalendarDate

0
    public static QName qname2 = new QName("urn://sample", "world" );
     
    static { 
        try { 
            df = DatatypeFactory.newInstance();
            bday = df.newXMLGregorianCalendarDate(1964, 12, 3,  DatatypeConstants.FIELD_UNDEFINED);
            holiday = bday = df.newXMLGregorianCalendarDate(2007, 1, 1,  DatatypeConstants.FIELD_UNDEFINED);
        } catch (Exception e) {}
    } 
     
     
     
    /** 
     * Echo the input 
     */ 
    public String testSimple(String simpleIn) {
        assertTrue(simpleIn != null);  // According to JAX-WS an RPC service should never receive a null
         
        // Test to ensure that returning null causes the proper exception  
        if (simpleIn.contains("returnNull")) {