## org.eclipse.emf.ecore.xml.type.internal
Class XMLDuration

    java.lang.Object
      javax.xml.datatype.Duration
          org.eclipse.emf.ecore.xml.type.internal.XMLDuration

All Implemented Interfaces:
  java.io.Serializable

    public final class XMLDuration

extends javax.xml.datatype.Duration
implements java.io.Serializable

An internal extension of Java's Duration to represent the W3C XML Schema 1.0 duration data type.

NOTE: this class is for internal use only.

See Also:
  Serialized Form

Constructor Summary
`XMLDuration(java.lang.String value)`

Method Summary
`javax.xml.datatype.Duration` `add(javax.xml.datatype.Duration rhs)`
`void` `addTo(java.util.Calendar calendar)`
`int` `compare(javax.xml.datatype.Duration duration)`
`static int` `compare(XMLDuration value1, XMLDuration value2)`
`boolean` `equals(java.lang.Object object)`
`int` `getDays()`
`java.lang.Number` `getField(javax.xml.datatype.DatatypeConstants.Field field)`
`int` `getHours()`
`int` `getMinutes()`
`int` `getMonths()`
`int` `getSeconds()`
`int` `getSign()`
`int` `getYears()`
`int` `hashCode()`
`boolean` `isSet(javax.xml.datatype.DatatypeConstants.Field field)`
`javax.xml.datatype.Duration` `multiply(java.math.BigDecimal factor)`
`javax.xml.datatype.Duration` `negate()`
`javax.xml.datatype.Duration` `normalizeWith(java.util.Calendar startTimeInstant)`
`java.lang.String` `toString()`

Methods inherited from class javax.xml.datatype.Duration
`addTo, getTimeInMillis, getTimeInMillis, getXMLSchemaType, isLongerThan, isShorterThan, multiply, subtract`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### XMLDuration

    public XMLDuration(java.lang.String value)

Method Detail

### compare

    public static int compare(XMLDuration value1,
                              XMLDuration value2)

### equals

    public boolean equals(java.lang.Object object)

  Overrides:
    `equals` in class `javax.xml.datatype.Duration`

### hashCode

    public int hashCode()

  Specified by:
    `hashCode` in class `javax.xml.datatype.Duration`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `javax.xml.datatype.Duration`

### add

    public javax.xml.datatype.Duration add(javax.xml.datatype.Duration rhs)

  Specified by:
    `add` in class `javax.xml.datatype.Duration`

### addTo

    public void addTo(java.util.Calendar calendar)

  Specified by:
    `addTo` in class `javax.xml.datatype.Duration`

### compare

    public int compare(javax.xml.datatype.Duration duration)

  Specified by:
    `compare` in class `javax.xml.datatype.Duration`

### getField

    public java.lang.Number getField(javax.xml.datatype.DatatypeConstants.Field field)

  Specified by:
    `getField` in class `javax.xml.datatype.Duration`

### getSign

    public int getSign()

  Specified by:
    `getSign` in class `javax.xml.datatype.Duration`

### getYears

    public int getYears()

  Overrides:
    `getYears` in class `javax.xml.datatype.Duration`

### getMonths

    public int getMonths()

  Overrides:
    `getMonths` in class `javax.xml.datatype.Duration`

### getDays

    public int getDays()

  Overrides:
    `getDays` in class `javax.xml.datatype.Duration`

### getHours

    public int getHours()

  Overrides:
    `getHours` in class `javax.xml.datatype.Duration`

### getMinutes

    public int getMinutes()

  Overrides:
    `getMinutes` in class `javax.xml.datatype.Duration`

### getSeconds

    public int getSeconds()

  Overrides:
    `getSeconds` in class `javax.xml.datatype.Duration`

### isSet

    public boolean isSet(javax.xml.datatype.DatatypeConstants.Field field)

  Specified by:
    `isSet` in class `javax.xml.datatype.Duration`

### multiply

    public javax.xml.datatype.Duration multiply(java.math.BigDecimal factor)

  Specified by:
    `multiply` in class `javax.xml.datatype.Duration`

### negate

    public javax.xml.datatype.Duration negate()

  Specified by:
    `negate` in class `javax.xml.datatype.Duration`

### normalizeWith

    public javax.xml.datatype.Duration normalizeWith(java.util.Calendar startTimeInstant)

  Specified by:
    `normalizeWith` in class `javax.xml.datatype.Duration`

Copyright 2001-2006 IBM Corporation and others. All Rights Reserved.