Interface TimeSelectorIF
-
- All Superinterfaces:
com.google.gwt.user.client.ui.IsWidget
- All Known Implementing Classes:
TimeSelector
public interface TimeSelectorIF extends com.google.gwt.user.client.ui.IsWidget
Interface defining a time selector- Author:
- Guy Griffiths
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description List<String>
getAvailableDates()
Return the available datesList<String>
getAvailableTimes()
Return the available timesString
getRange()
String
getSelectedDate()
String
getSelectedDateTime()
String
getSelectedDateTimeRange()
String
getSelectedTime()
boolean
hasMultipleTimes()
boolean
isContinuous()
void
populateDates(List<String> availableDates)
Populate the available datesvoid
populateTimes(List<String> availableTimes)
Populate the available times.boolean
selectDate(String dateString)
Choose a specified dateboolean
selectDateTime(String timeString)
Choose a specified datetimevoid
selectRange(String currentRange)
Sets the range (i.e.void
setContinuous(boolean continuous)
Sets whether thisTimeSelectorIF
needs to represent discrete or continous timevoid
setEnabled(boolean enabled)
Enable/disable the widgetvoid
setId(String id)
Sets the ID of the layer which this time selector applies to
-
-
-
Method Detail
-
setId
void setId(String id)
Sets the ID of the layer which this time selector applies to- Parameters:
id
-
-
populateTimes
void populateTimes(List<String> availableTimes)
Populate the available times. This may change as the date changes
-
getSelectedDate
String getSelectedDate()
- Returns:
- A
String
representation of the currently selected date
-
getSelectedDateTime
String getSelectedDateTime()
- Returns:
- A
String
representation of the currently selected datetime
-
getSelectedTime
String getSelectedTime()
- Returns:
- A
String
representation of the currently selected time
-
getSelectedDateTimeRange
String getSelectedDateTimeRange()
- Returns:
- A
String
representation of the currently selected datetime range. This may benull
if isContinous() returns false
-
selectDate
boolean selectDate(String dateString)
Choose a specified date- Parameters:
dateString
- The desired date- Returns:
true
if the operation was successfull
-
selectDateTime
boolean selectDateTime(String timeString)
Choose a specified datetime- Parameters:
timeString
- The desired datetime- Returns:
true
if the operation was successfull
-
setEnabled
void setEnabled(boolean enabled)
Enable/disable the widget- Parameters:
enabled
-true
to enable the widget,false
to disable it
-
hasMultipleTimes
boolean hasMultipleTimes()
- Returns:
true
if this time selector can represent multiple datetimes
-
setContinuous
void setContinuous(boolean continuous)
Sets whether thisTimeSelectorIF
needs to represent discrete or continous time- Parameters:
continuous
-
-
isContinuous
boolean isContinuous()
- Returns:
true
if thisTimeSelectorIF
is currently representing a continuous time range,false
if it is a discrete one
-
selectRange
void selectRange(String currentRange)
Sets the range (i.e. +/- how much) for a continuous axis- Parameters:
currentRange
-
-
getRange
String getRange()
- Returns:
- The currently selected range (i.e. +/- how much) for a continuous axis
-
-