InteractionExtensions.CreateMessage 方法
创建一条在指定生命线上开始和结束的完整消息。
命名空间: Microsoft.VisualStudio.ArchitectureTools.Extensibility.Uml
程序集: Microsoft.VisualStudio.ArchitectureTools.Extensibility(在 Microsoft.VisualStudio.ArchitectureTools.Extensibility.dll 中)
语法
声明
<ExtensionAttribute> _
Public Shared Function CreateMessage ( _
parent As IInteraction, _
sourceInsertionPoint As IInsertionPoint, _
targetInsertionPoint As IInsertionPoint, _
messageKind As MessageKind, _
messageSort As MessageSort _
) As IMessage
public static IMessage CreateMessage(
this IInteraction parent,
IInsertionPoint sourceInsertionPoint,
IInsertionPoint targetInsertionPoint,
MessageKind messageKind,
MessageSort messageSort
)
[ExtensionAttribute]
public:
static IMessage^ CreateMessage(
IInteraction^ parent,
IInsertionPoint^ sourceInsertionPoint,
IInsertionPoint^ targetInsertionPoint,
MessageKind messageKind,
MessageSort messageSort
)
static member CreateMessage :
parent:IInteraction *
sourceInsertionPoint:IInsertionPoint *
targetInsertionPoint:IInsertionPoint *
messageKind:MessageKind *
messageSort:MessageSort -> IMessage
public static function CreateMessage(
parent : IInteraction,
sourceInsertionPoint : IInsertionPoint,
targetInsertionPoint : IInsertionPoint,
messageKind : MessageKind,
messageSort : MessageSort
) : IMessage
参数
- sourceInsertionPoint
类型:Microsoft.VisualStudio.ArchitectureTools.Extensibility.Uml.IInsertionPoint
发送生命线上的插入点。
- targetInsertionPoint
类型:Microsoft.VisualStudio.ArchitectureTools.Extensibility.Uml.IInsertionPoint
接收生命线上的插入点。
- messageKind
类型:Microsoft.VisualStudio.Uml.Interactions.MessageKind
必须是 MessageKind.Complete。将 CreateLostOrFoundMessage() 用于其它 MessageKinds
- messageSort
类型:Microsoft.VisualStudio.Uml.Interactions.MessageSort
同步 = 消息包含返回的部分 ; 异步 = 消息不包含返回的部分。
返回值
类型:Microsoft.VisualStudio.Uml.Interactions.IMessage
使用说明
在 Visual Basic 和 C# 中,可以在 IInteraction 类型的任何对象上将此方法作为实例方法来调用。当使用实例方法语法调用此方法时,请省略第一个参数。有关更多信息,请参见扩展方法 (Visual Basic)或扩展方法(C# 编程指南)。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。
请参见
参考
Microsoft.VisualStudio.ArchitectureTools.Extensibility.Uml 命名空间