Package com.nomagic.magicdraw.uml2
Class Interactions
- java.lang.Object
-
- com.nomagic.magicdraw.uml2.Interactions
-
public class Interactions extends java.lang.Object
Convenient static methods to work with Interactions elements.
-
-
Constructor Summary
Constructors Constructor Description Interactions()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Message
getMessageSubstitute(Message message)
Returns message substitute for given message or the given message, if no substitution found.static Operation
getOperationOfCallMessage(Message message)
Gets the operation of call message.static Element
getReceiveElement(Message message)
Gets the receive element.static ConnectableElement
getRemovableConnectableElement(Lifeline lifeline)
Check if the represents can be removed along with lifeline.static Element
getSendElement(Message message)
Return send event holder of the given message.static Signal
getSignalOfMessage(Message message)
Gets the signal of message.static boolean
isCallMessage(Message message)
Indicates if message is a call message.static boolean
isCreateMessage(Message msg)
Checks if is creates the message.static boolean
isDestroyMessage(Message msg)
Checks if is destroy message.static boolean
isFoundMessage(Message message)
Indicates if given message is a found message.static boolean
isLostMessage(Message message)
Indicates if given message is a lost message.static boolean
isReplyMessage(Message message)
Indicates if this message is a reply message.static boolean
isSendMessage(Message message)
Checks if is send message.static boolean
isSynchMessage(Message msg)
Checks if is synch message.
-
-
-
Method Detail
-
getReceiveElement
@CheckForNull public static Element getReceiveElement(Message message)
Gets the receive element.- Parameters:
message
- the message- Returns:
- the receive element
-
getSendElement
@CheckForNull public static Element getSendElement(Message message)
Return send event holder of the given message.It can be:
- covered lifeline
- gate owner (Interaction, CombinedFragment, InteractionUse)
- Parameters:
message
- Given message, which will be analysed- Returns:
- One of Lifeline, Interaction, CombinedFragment, InteractionUse. Can return null, if message has no send event
-
getRemovableConnectableElement
@CheckForNull public static ConnectableElement getRemovableConnectableElement(Lifeline lifeline)
Check if the represents can be removed along with lifeline.- Parameters:
lifeline
- lifeline- Returns:
- connectible element that should be disposed
-
getSignalOfMessage
@CheckForNull public static Signal getSignalOfMessage(Message message)
Gets the signal of message.- Parameters:
message
- the message- Returns:
- the signal of message
-
isSendMessage
public static boolean isSendMessage(Message message)
Checks if is send message.- Parameters:
message
- the message- Returns:
- true, if is send message
-
isLostMessage
public static boolean isLostMessage(Message message)
Indicates if given message is a lost message.- Parameters:
message
- message to check.- Returns:
- true if given message is a lost message, false otherwise.
-
isFoundMessage
public static boolean isFoundMessage(Message message)
Indicates if given message is a found message.- Parameters:
message
- message to check.- Returns:
- true if given message is a found message, false otherwise.
-
isSynchMessage
public static boolean isSynchMessage(Message msg)
Checks if is synch message.- Parameters:
msg
- the msg- Returns:
- true, if is synch message
-
isDestroyMessage
public static boolean isDestroyMessage(Message msg)
Checks if is destroy message.- Parameters:
msg
- the msg- Returns:
- true, if is destroy message
-
isReplyMessage
public static boolean isReplyMessage(Message message)
Indicates if this message is a reply message.- Parameters:
message
- - message to check.- Returns:
- true if this is a reply message, false otherwise.
-
isCallMessage
public static boolean isCallMessage(Message message)
Indicates if message is a call message.- Parameters:
message
- - message to check.- Returns:
- true if this message is a call message, false otherwise.
-
isCreateMessage
public static boolean isCreateMessage(Message msg)
Checks if is creates the message.- Parameters:
msg
- the msg- Returns:
- true, if is creates the message
-
getMessageSubstitute
public static Message getMessageSubstitute(Message message)
Returns message substitute for given message or the given message, if no substitution found. Message substitution is message found by the formal gate.- Parameters:
message
- message, for which substitution will be searched- Returns:
- given message if no substitution found
-
-