Package org.gedcomx.date
Class GedcomxDateDuration
java.lang.Object
org.gedcomx.date.GedcomxDate
org.gedcomx.date.GedcomxDateDuration
- All Implemented Interfaces:
Comparable<GedcomxDate>
The duration between two simple dates
- Author:
- John Clark.
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a new duration from the formal string -
Method Summary
Methods inherited from class org.gedcomx.date.GedcomxDate
compareTo
-
Constructor Details
-
GedcomxDateDuration
Create a new duration from the formal string- Parameters:
str- The formal duration string
-
-
Method Details
-
getType
The type of this date- Specified by:
getTypein classGedcomxDate- Returns:
- The date type
-
isApproximate
public boolean isApproximate()A Duration is NEVER Approximate- Specified by:
isApproximatein classGedcomxDate- Returns:
- True if the duration is approximate (It never is)
-
toFormalString
The formal string representation of the duration- Specified by:
toFormalStringin classGedcomxDate- Returns:
- The formal string
-
getYears
Get the years- Returns:
- The Years
-
getMonths
Get the months- Returns:
- The Months
-
getDays
Get the days- Returns:
- The Days
-
getHours
Get the hours- Returns:
- The Hours
-
getMinutes
Get the minutes- Returns:
- The Minutes
-
getSeconds
Get the seconds- Returns:
- The Seconds
-