Coverage Report - org.apache.xmlrpc.serializer.DateSerializer
 
Classes in this File Line Coverage Branch Coverage Complexity
DateSerializer
50% 
N/A 
1
 
 1  
 /*
 2  
  * Copyright 1999,2005 The Apache Software Foundation.
 3  
  * 
 4  
  * Licensed under the Apache License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  * 
 8  
  *      http://www.apache.org/licenses/LICENSE-2.0
 9  
  * 
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13  
  * See the License for the specific language governing permissions and
 14  
  * limitations under the License.
 15  
  */
 16  
 package org.apache.xmlrpc.serializer;
 17  
 
 18  
 import org.apache.ws.commons.util.XsDateTimeFormat;
 19  
 import org.xml.sax.ContentHandler;
 20  
 import org.xml.sax.SAXException;
 21  
 
 22  
 
 23  
 /** A {@link TypeSerializer} for date values.
 24  
  */
 25  2
 public class DateSerializer extends TypeSerializerImpl {
 26  
         /** Tag name of a date value.
 27  
          */
 28  
         public static final String DATE_TAG = "dateTime.iso8601";
 29  1
         private static final XsDateTimeFormat format = new XsDateTimeFormat();
 30  
         public void write(ContentHandler pHandler, Object pObject) throws SAXException {
 31  0
                 write(pHandler, DATE_TAG, format.format(pObject));
 32  0
         }
 33  
 }