Class YearMonthXmlAdapter


  • public class YearMonthXmlAdapter
    extends XmlAdapter<java.lang.String,​java.time.YearMonth>
    XmlAdapter mapping JSR-310 YearMonth to a string such as 2007-12

    String format details:

    • YearMonth.parse(java.lang.CharSequence)
    • YearMonth.toString()

    This adapter is suitable for xsd:gYearMonth types.

    See Also:
    XmlAdapter, YearMonth
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String marshal​(java.time.YearMonth value)  
      java.time.YearMonth unmarshal​(java.lang.String stringValue)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • YearMonthXmlAdapter

        public YearMonthXmlAdapter()
    • Method Detail

      • unmarshal

        public java.time.YearMonth unmarshal​(java.lang.String stringValue)
        Specified by:
        unmarshal in class XmlAdapter<java.lang.String,​java.time.YearMonth>
      • marshal

        public java.lang.String marshal​(java.time.YearMonth value)
        Specified by:
        marshal in class XmlAdapter<java.lang.String,​java.time.YearMonth>