public class TimeInstant extends Time
Time.NilReason, Time.RelativePosition, Time.TimeFormat, Time.TimeIndeterminateValue
Modifier and Type | Field and Description |
---|---|
private Time.TimeIndeterminateValue |
indeterminateValue
Indeterminate value
|
private int |
requestedTimeLength
length of timeInstant date
|
private static long |
serialVersionUID
serial number
|
private SosConstants.SosIndeterminateTime |
sosIndeterminateTime
SOS indeterminate time, e.g.
|
private org.joda.time.DateTime |
value
date for this timeInstant
|
Constructor and Description |
---|
TimeInstant()
default constructor
|
TimeInstant(Date date)
Constructor using Java Dates, setting unknown indeterminate values if
null
|
TimeInstant(org.joda.time.DateTime dateTime)
constructor
|
TimeInstant(org.joda.time.DateTime dateValue,
Time.TimeIndeterminateValue indeterminateValue)
constructor with date and indeterminateValue.
|
TimeInstant(SosConstants.SosIndeterminateTime sosIndeterminateTime)
constructor
|
TimeInstant(Time.TimeIndeterminateValue indeterminateValue)
constructor
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Time o) |
boolean |
equals(Object paramObject) |
Time.TimeIndeterminateValue |
getIndeterminateValue()
Get indeterminate value
|
int |
getRequestedTimeLength()
Get requested time length
|
SosConstants.SosIndeterminateTime |
getSosIndeterminateTime()
Get SOS indeterminate value
|
TimePosition |
getTimePosition()
Get the time position of this time instant
|
org.joda.time.DateTime |
getValue()
Get time value
|
int |
hashCode() |
boolean |
isEmpty()
Check if time is empty
|
boolean |
isIndeterminateValueEqualTo(Enum value)
Check whether this indeterminate value equals expected value
|
boolean |
isSetIndeterminateValue()
Check if indeterminate value is set
|
boolean |
isSetSosIndeterminateTime()
Check if SOS indeterminate value is set
|
boolean |
isSetValue()
Check if time value is set
|
org.joda.time.DateTime |
resolveValue()
Get time value, resolving indeterminate value if value is null
|
Time |
setIndeterminateValue(Time.TimeIndeterminateValue indeterminateValue)
Set indeterminate value
|
void |
setRequestedTimeLength(int requestedTimeLength)
Set requested time length
|
TimeInstant |
setSosIndeterminateTime(SosConstants.SosIndeterminateTime sosIndeterminateTime)
Set SOS indeterminate value
|
void |
setValue(org.joda.time.DateTime value)
Set time value
|
String |
toString() |
getGmlId, getNilReason, getReference, getTimeFormat, isNilReasonEqualTo, isReferenced, isSetGmlId, isSetNilReason, isSetReference, isSetTimeFormat, resolveDateTime, setGmlId, setNilReason, setReference, setTimeFormat
private static final long serialVersionUID
private org.joda.time.DateTime value
private int requestedTimeLength
private SosConstants.SosIndeterminateTime sosIndeterminateTime
SosConstants.SosIndeterminateTime.first
,
SosConstants.SosIndeterminateTime.latest
private Time.TimeIndeterminateValue indeterminateValue
public TimeInstant()
public TimeInstant(org.joda.time.DateTime dateTime)
dateTime
- Time position of this time instantpublic TimeInstant(Time.TimeIndeterminateValue indeterminateValue)
indeterminateValue
- Indeterminate valuepublic TimeInstant(SosConstants.SosIndeterminateTime sosIndeterminateTime)
sosIndeterminateTime
- SOS indeterminate timepublic TimeInstant(org.joda.time.DateTime dateValue, Time.TimeIndeterminateValue indeterminateValue)
dateValue
- date of the timeInstanteindeterminateValue
- Indeterminate valuepublic TimeInstant(Date date)
date
- Value datepublic org.joda.time.DateTime getValue()
public org.joda.time.DateTime resolveValue()
public void setValue(org.joda.time.DateTime value)
value
- The value to set.public void setRequestedTimeLength(int requestedTimeLength)
requestedTimeLength
- the requestedTimeLength to setpublic int getRequestedTimeLength()
public int compareTo(Time o)
public boolean isSetValue()
public Time.TimeIndeterminateValue getIndeterminateValue()
public TimePosition getTimePosition()
public Time setIndeterminateValue(Time.TimeIndeterminateValue indeterminateValue)
indeterminateValue
- The indeterminateValue to set.public boolean isSetIndeterminateValue()
public boolean isIndeterminateValueEqualTo(Enum value)
value
- Expected valuetrue
, if this indeterminate value equals expected
valuepublic SosConstants.SosIndeterminateTime getSosIndeterminateTime()
public TimeInstant setSosIndeterminateTime(SosConstants.SosIndeterminateTime sosIndeterminateTime)
sosIndeterminateTime
- public boolean isSetSosIndeterminateTime()
public boolean isEmpty()
Time
isEmpty
in class Time
isSetValue()
,
isSetIndeterminateValue()
Copyright © 2012-2015 52north.org. All Rights Reserved.