public class CalendarableItem extends ModelObject
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
BINDING_KEY
(Non-API)
|
static java.util.Comparator |
comparator
A comparator for CalendarableItem objects
|
static java.lang.String |
DATA_KEY
(Non-API)
|
static java.lang.String |
PROP_ALL_DAY_EVENT
A constant representing the name of the allDayEvent property.
|
static java.lang.String |
PROP_CONTINUED
A constant representing the name of the continued property.
|
static java.lang.String |
PROP_DATA
A constant representing the name of the data property.
|
static java.lang.String |
PROP_END_TIME
A constant representing the name of the endTime property.
|
static java.lang.String |
PROP_IMAGE
A constant representing the name of the image property.
|
static java.lang.String |
PROP_START_TIME
A constant representing the name of the startTime property.
|
static java.lang.String |
PROP_TEXT
A constant representing the name of the text property.
|
static java.lang.String |
PROP_TOOL_TIP_TEXT
A constant representing the name of the toolTipText property.
|
Constructor and Description |
---|
CalendarableItem(java.util.Date day) |
Modifier and Type | Method and Description |
---|---|
int |
getContinued() |
ICalendarableItemControl |
getControl()
(non-API)
Returns the UI control for this CalendarableItem.
|
java.lang.Object |
getData()
Returns the application defined widget data associated
with the receiver, or null if it has not been set.
|
java.lang.Object |
getData(java.lang.String key)
Returns the application defined property of the receiver
with the specified name, or null if it has not been set.
|
java.util.Date |
getDate() |
java.util.Date |
getEndTime()
Returns the event's end time.
|
org.eclipse.swt.graphics.Image |
getImage()
Return the IEvent's image or
null . |
org.eclipse.swt.graphics.Point |
getLowerRightPositionInDayRowCoordinates()
(non-API)
|
java.util.Date |
getStartTime()
Gets the event's start time.
|
java.lang.String |
getText()
Returns the widget text.
|
java.lang.String |
getToolTipText()
Returns the receiver's tool tip text, or null if it has
not been set.
|
org.eclipse.swt.graphics.Point |
getUpperLeftPositionInDayRowCoordinates()
(non-API)
|
boolean |
isAllDayEvent()
Returns if this Calenderable represents an all-day event.
|
void |
setAllDayEvent(boolean allDayEvent)
Sets if this Calenderable represents an all-day event.
|
void |
setContinued(int continued)
Sets the "To be continued..." bitmask indicating that this event is
continued on the next or previous days respectively.
|
void |
setControl(ICalendarableItemControl control)
(non-API)
Set the UI control for this CalendarableItem.
|
void |
setData(java.lang.Object data)
Sets the application defined widget data associated
with the receiver to be the argument.
|
void |
setData(java.lang.String key,
java.lang.Object data)
Sets the application defined property of the receiver
with the specified name to the given value.
|
void |
setDate(java.util.Date date) |
void |
setEndTime(java.util.Date endTime)
Sets the event's end time.
|
void |
setImage(org.eclipse.swt.graphics.Image image)
Set the IEvent's Image.
|
void |
setLowerRightPositionInDayRowCoordinates(org.eclipse.swt.graphics.Point lowerRightPositionInDayRowCoordinates)
(non-API)
Sets the lower right position of the bounding box.
|
void |
setStartTime(java.util.Date startTime)
Sets the event's start time.
|
void |
setText(java.lang.String string)
Sets the contents of the receiver to the given string.
|
void |
setToolTipText(java.lang.String string)
Sets the receiver's tool tip text to the argument, which
may be null indicating that no tool tip text should be shown.
|
void |
setUpperLeftPositionInDayRowCoordinates(org.eclipse.swt.graphics.Point upperLeftPositionInDayRowCoordinates)
(non-API)
Sets the upper left position of the bounding box and initializes the
lower right position to be the same as the upper left if the lower right
has not yet been set.
|
addPropertyChangeListener, addPropertyChangeListener, append, firePropertyChange, firePropertyChange, firePropertyChange, remove, removePropertyChangeListener, removePropertyChangeListener, setId
public static final java.lang.String PROP_TOOL_TIP_TEXT
public static final java.lang.String PROP_DATA
public static final java.lang.String PROP_TEXT
public static final java.lang.String PROP_IMAGE
public static final java.lang.String PROP_END_TIME
public static final java.lang.String PROP_START_TIME
public static final java.lang.String PROP_ALL_DAY_EVENT
public static final java.lang.String PROP_CONTINUED
public static final java.util.Comparator comparator
public static final java.lang.String BINDING_KEY
public static final java.lang.String DATA_KEY
public boolean isAllDayEvent()
public void setAllDayEvent(boolean allDayEvent)
allDayEvent
- true if this is an all-day event; false otherwise.public java.util.Date getDate()
public void setDate(java.util.Date date)
date
- Sets the date on which the event falls. Ignores the time
component of the date that is passed in.public java.util.Date getStartTime()
public void setStartTime(java.util.Date startTime)
startTime
- the event's start time.public java.util.Date getEndTime()
public void setEndTime(java.util.Date endTime)
endTime
- the event's end time. This value is ignored if this is an all-day event.public org.eclipse.swt.graphics.Image getImage()
null
.public void setImage(org.eclipse.swt.graphics.Image image)
null
clears it.image
- the image to be displayed in the label or nullorg.eclipse.swt.SWTException
- public java.lang.String getText()
The text for a text widget is the characters in the widget, or an empty string if this has never been set.
org.eclipse.swt.SWTException
- public void setText(java.lang.String string)
string
- the new textjava.lang.IllegalArgumentException
- org.eclipse.swt.SWTException
- public java.lang.String getToolTipText()
org.eclipse.swt.SWTException
- public void setToolTipText(java.lang.String string)
string
- the new tool tip text (or null)org.eclipse.swt.SWTException
- public java.lang.Object getData()
Applications may put arbitrary objects in this field. If the object stored in the widget data needs to be notified when the widget is disposed of, it is the application's responsibility to hook the Dispose event on the widget and do so.
setData(Object)
public void setData(java.lang.Object data)
Applications may put arbitrary objects in this field. If the object stored in the widget data needs to be notified when the widget is disposed of, it is the application's responsibility to hook the Dispose event on the widget and do so.
data
- the widget datagetData()
public void setData(java.lang.String key, java.lang.Object data)
Applications may associate arbitrary objects with the receiver in this fashion.
key
- the name of the propertyvalue
- the new value for the propertyjava.lang.IllegalArgumentException
- getData(String)
public java.lang.Object getData(java.lang.String key)
Applications may have associated arbitrary objects with the receiver in this fashion.
key
- the name of the propertyjava.lang.IllegalArgumentException
- setData(String, Object)
public org.eclipse.swt.graphics.Point getUpperLeftPositionInDayRowCoordinates()
public void setUpperLeftPositionInDayRowCoordinates(org.eclipse.swt.graphics.Point upperLeftPositionInDayRowCoordinates)
upperLeftPositionInDayRowCoordinates
- The upperLeftPositionInDayRowCoordinates to set.public org.eclipse.swt.graphics.Point getLowerRightPositionInDayRowCoordinates()
public void setLowerRightPositionInDayRowCoordinates(org.eclipse.swt.graphics.Point lowerRightPositionInDayRowCoordinates)
lowerRightPositionInDayRowCoordinates
- The lowerRightPositionInDayRowCoordinates to set.public ICalendarableItemControl getControl()
public void setControl(ICalendarableItemControl control)
control
- The control to set.public void setContinued(int continued)
continued
- One or both of SWT.TOP or SWT.BOTTOMpublic int getContinued()