|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectse.umu.cs.SequenceDiagramEditor.Entity
se.umu.cs.SequenceDiagramEditor.Message
This class represents a message.
Field Summary | |
private ClassEntity |
endEntity
The endentity of the message. |
private boolean |
isCreateMessage
Tells if the message is a creationmessage or not. |
private boolean |
isReturnMessage
Tells if the message is a returnmessage or not. |
private javax.swing.JMenuItem |
menuChangeMessage
The menuitem for changing the message. |
private javax.swing.JMenuItem |
menuDelete
The menuitem for deleting the message. |
private boolean |
moveObject
Tells if the message could be moved or not. |
private boolean |
moveStart
Tells if the message could be moved or not. |
private Message |
returnMessage
The return message belonging to the message. |
private int |
sequenceIndex
If the message is in a sequence this is the index of the message in the sequence. |
private ClassEntity |
startEntity
The startentity of the message. |
private Handle |
startHandle
The handle of the message, used to move the messaga. |
private boolean |
validEnd
Tells if the end of the message is valid or not. |
Fields inherited from class se.umu.cs.SequenceDiagramEditor.Entity |
drawingArea, endPoint, lifeLine, name, selected, startPoint, string |
Constructor Summary | |
Message(DrawingArea d)
The constructor of the class. |
Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
This method is called when an ActionEvent takes place. |
void |
changeMessage()
This method is called when the user wants to change the message. |
void |
delete()
This method is called to delete a message. |
void |
draw(java.awt.Graphics g)
This method is called to draw the object. |
ClassEntity |
getEndEntity()
This method returns the endentity of the message. |
boolean |
getIsCreateMessage()
Returns whether the message is a creation message or not. |
boolean |
getIsReturnMessage()
Returns whether the message is a return message or not. |
int |
getNextState()
This method returns the next state for this class. |
Message |
getReturnMessage()
This method returns the return message belonging to this message. |
int |
getSequenceIndex()
This method returns the index of the message in a sequence. |
ClassEntity |
getStartEntity()
This method returns the startentity of the message. |
boolean |
isClickedOn(java.awt.Point p)
This method decides whether the object is clicked on or not. |
void |
setEndEntity(ClassEntity end)
This method sets the endentity of the message. |
void |
setEndPoint(java.awt.Point p)
This method sets the endpoint for the object. |
void |
setIsCreateMessage(boolean b)
This method sets whether the message is a creation message or not. |
void |
setIsReturnMessage(boolean b)
Sets if the message is a return message or not. |
void |
setNextState(java.awt.Point p)
This method is called to update the next state of the class based upon what the user has choosen. |
void |
setReturnMessage(Message retMess)
This method sets the return message of the message. |
void |
setSelected(boolean b)
This method sets the object selected or not selected. |
void |
setSequenceIndex(int i)
This method sets the index in the sequence for the message. |
void |
setStartEntity(ClassEntity start)
This method sets the startentity of the message. |
void |
setStartHandle(Handle h)
This method sets the handle of the message. |
void |
setStartPoint(java.awt.Point p)
This method sets the startpoint for the object. |
void |
showMenu(java.awt.Point p)
This method is called to show the menu of the object. |
Methods inherited from class se.umu.cs.SequenceDiagramEditor.Entity |
getEndPoint, getName, getStartPoint, getString, modifyString, setName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private javax.swing.JMenuItem menuChangeMessage
private javax.swing.JMenuItem menuDelete
private ClassEntity startEntity
private ClassEntity endEntity
private Handle startHandle
private boolean moveStart
private boolean validEnd
private boolean moveObject
private boolean isCreateMessage
private boolean isReturnMessage
private Message returnMessage
private int sequenceIndex
Constructor Detail |
public Message(DrawingArea d)
d
- The component where the message will be drawn.Method Detail |
public void draw(java.awt.Graphics g)
draw
in class Entity
g
- Used for the drawing.public void setStartPoint(java.awt.Point p)
setStartPoint
in class Entity
p
- The startpoint.public void setEndPoint(java.awt.Point p)
setEndPoint
in class Entity
p
- The endpoint.public void showMenu(java.awt.Point p)
showMenu
in class Entity
p
- The menu will be shown at the given point.public int getNextState()
getNextState
in class Entity
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
e
- The ActionEvent.public void changeMessage()
public boolean isClickedOn(java.awt.Point p)
isClickedOn
in class Entity
p
- The point where the user has clicked.
public void delete()
public void setNextState(java.awt.Point p)
setNextState
in class Entity
p
- The point of the mouse.public void setSelected(boolean b)
setSelected
in class Entity
b
- True if the object is selected, otherwise false.public ClassEntity getStartEntity()
public void setStartEntity(ClassEntity start)
start
- The startentitypublic void setEndEntity(ClassEntity end)
end
- The endentitypublic ClassEntity getEndEntity()
public void setStartHandle(Handle h)
h
- The handlepublic void setIsCreateMessage(boolean b)
b
- True if creation message else falsepublic boolean getIsCreateMessage()
public boolean getIsReturnMessage()
public void setIsReturnMessage(boolean b)
b
- True if return message else falsepublic Message getReturnMessage()
public void setReturnMessage(Message retMess)
retMess
- The return messagepublic void setSequenceIndex(int i)
i
- The indexpublic int getSequenceIndex()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |