UserTrackingLocation 类

定义

警告

此 API 现已过时。

定义与根工作流实例的可能执行路径中的某个用户事件相对应的活动限定位置。Defines an activity-qualified location that corresponds to a user event in the potential execution path of a root workflow instance. 此类不能被继承。This class cannot be inherited.

public ref class UserTrackingLocation sealed
[System.Serializable]
public sealed class UserTrackingLocation
[System.Obsolete("The System.Workflow.* types are deprecated.  Instead, please use the new types from System.Activities.*")]
[System.Serializable]
public sealed class UserTrackingLocation
type UserTrackingLocation = class
Public NotInheritable Class UserTrackingLocation
继承
UserTrackingLocation
属性

注解

备注

本材料讨论的类型和命名空间已废弃不用。This material discusses types and namespaces that are obsolete. 有关详细信息,请参阅 Windows Workflow Foundation 4.5 中弃用的类型For more information, see Deprecated Types in Windows Workflow Foundation 4.5.

活动设计器或工作流设计器可以使用任何重载 Activity.TrackDataActivityExecutionContext.TrackData 方法来检测工作流,以便采用用户事件的形式将数据发出到运行时跟踪基础结构。An activity designer or a workflow designer may use any of the overloaded Activity.TrackData and ActivityExecutionContext.TrackData methods to instrument the workflow to emit data to the runtime tracking infrastructure as a user event. 发出的数据称为用户数据。The data emitted is referred to as user data. 与只会在活动或工作流状态更改时发生的活动状态事件和工作流状态事件不同,用户事件可以在工作流中检测到的任何位置发生。Unlike activity status events, and workflow status events, which occur only on activity or workflow status changes, user events can occur at any location that is instrumented in a workflow. UserTrackingLocation 通过指定以下各项为这种位置定义匹配参数:用户数据的类型、必须从中发出用户数据的活动的类型、可以对此活动的一个或多个实例加以更精确限定的条件的集合、用户数据必须与之关联的可选键名、用户数据的派生类型是否应匹配,以及从活动(派生自指定活动的类型)中发出的用户数据是否应匹配。A UserTrackingLocation defines the matching parameters for such a location by specifying the type of the user data, the type of the activity from which it must be emitted, a collection of conditions that can more precisely qualify an instance or instances of this activity, an optional key name with which the user data must be associated, whether derived types of the user data should be matched, and whether user data emitted from activities derived from the type of the specified activity should be matched.

备注

单一 UserTrackingLocation 可以引用工作流实例的可能执行路径中的多个实际位置。A single UserTrackingLocation may refer to more than one actual location in the potential execution path of a workflow instance.

您可以将 UserTrackingLocation 添加到 UserTrackPoint.MatchingLocationsUserTrackPoint.ExcludedLocations,以便为 UserTrackPoint 中的 TrackingProfile 定义匹配参数。You may add a UserTrackingLocation to either UserTrackPoint.MatchingLocations or UserTrackPoint.ExcludedLocations in order to define the match parameters for a UserTrackPoint in a TrackingProfile.

对于要由运行时跟踪基础结构匹配的 UserTrackingLocation,必须按如下顺序满足以下三个一般条件:发出用户事件的活动必须与 ActivityTypeActivityTypeNameConditionsMatchDerivedActivityTypes 指定的活动集合相匹配;与用户数据关联的键(如果存在)必须与 KeyName 相匹配;并且,用户事件发出的用户数据的类型必须与 ArgumentTypeArgumentTypeNameMatchDerivedArgumentTypes 指定的用户数据类型的集合相匹配。There are three general conditions which must be met in the following order for the UserTrackingLocation to be matched by the runtime tracking infrastructure: the activity that has emitted a user event must match the set of activities specified by ActivityType, ActivityTypeName, Conditions, and MatchDerivedActivityTypes; the key, if one exists, associated with the user data must match KeyName; and, the type of the user data emitted by the user event must match the set of user data types specified by ArgumentType, ArgumentTypeName, and MatchDerivedArgumentTypes. 只有在所有这三个条件都得到满足时,运行时跟踪基础结构才会认为 UserTrackingLocation 匹配。Only if all three of these conditions are met, does the runtime tracking infrastructure consider the UserTrackingLocation matched.

若要配置 UserTrackingLocation,必须设置 ArgumentTypeNameArgumentType 以指定要匹配的用户数据类型,并设置 ActivityTypeNameActivityType 以指定必须从中发出要匹配的用户数据的活动类型。To configure a UserTrackingLocation, you must set either ArgumentTypeName or ArgumentType to specify the type of the user data to be matched and either ActivityTypeName or ActivityType to specify the type of the activity from which the user data must be emitted to be matched. 您可以将 ActivityTrackingCondition 对象添加到 Conditions,以便更完全地限定必须从中发出用户数据的活动。You may add ActivityTrackingCondition objects to Conditions to more completely qualify the activity from which the user data must be emitted. 您可以设置 MatchDerivedArgumentTypes,以指定应当匹配派生自用户数据类型(由 ArgumentTypeNameArgumentType 指定)的用户数据,并且可以设置 MatchDerivedActivityTypes,以指定应当匹配从派生自活动类型(由 ActivityTypeNameActivityType 指定)的活动中发出的用户数据。You may set MatchDerivedArgumentTypes to specify that user data derived from the user data type specified by ArgumentTypeName or ArgumentType should be matched, and you may set MatchDerivedActivityTypes to specify that user data emitted from activities derived from the activity type specified by ActivityTypeName or ActivityType should be matched.

您可以设置 KeyName 以指定只应为此 UserTrackingLocation 匹配与指定键名关联的用户数据。You may set KeyName to specify that only user data associated with the specified key name should be matched for this UserTrackingLocation. 如果 KeyName 为空引用(在 Visual Basic 中为 Nothing),运行时跟踪结构将不会尝试匹配与用户数据关联的键。If KeyName is a null reference (Nothing in Visual Basic), the runtime tracking structure will not try to match the key associated with the user data.

构造函数

UserTrackingLocation()

初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class.

UserTrackingLocation(String)

使用用户数据的公共语言运行库 (CLR) 类型的非限定名称初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class by using the unqualified name of the common language runtime (CLR) type of the user data.

UserTrackingLocation(String, String)

使用用户数据的公共语言运行库 (CLR) 类型的非限定名称以及活动(必须从中发出用户数据)的 CLR 类型的非限定名称初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class by using the unqualified name of the common language runtime (CLR) type of the user data and the unqualified name of the CLR type of the activity from which the user data must be emitted.

UserTrackingLocation(String, Type)

使用用户数据的公共语言运行库 (CLR) 类型的非限定名称以及活动(必须从中发出用户数据)的 CLR 类型初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class by using the unqualified name of the common language runtime (CLR) type of the user data and the CLR type of the activity from which the user data must be emitted.

UserTrackingLocation(Type)

使用用户数据的公共语言运行库 (CLR) 类型初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class using the common language runtime (CLR) type of the user data.

UserTrackingLocation(Type, String)

使用用户数据的公共语言运行库 (CLR) 类型以及活动(必须从中发出用户数据)的 CLR 类型的非限定名称初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class by using the common language runtime (CLR) type of the user data and unqualified name of the CLR type of the activity from which the user data must be emitted.

UserTrackingLocation(Type, Type)

使用用户数据的公共语言运行库 (CLR) 类型以及活动(必须从中发出用户数据)的 CLR 类型初始化 UserTrackingLocation 类的新实例。Initializes a new instance of the UserTrackingLocation class by using the common language runtime (CLR) type of the user data and the CLR type of the activity from which the user data must be emitted.

属性

ActivityType

获取或设置必须从中发出要跟踪的用户数据的活动的公共语言运行库 (CLR) 类型。Gets or sets the common language runtime (CLR) type of the activity from which the user data must be emitted to be tracked.

ActivityTypeName

获取或设置必须从中发出要跟踪的用户数据的活动的公共语言运行库 (CLR) 类型的非限定名称。Gets or sets the unqualified name of the common language runtime (CLR) type of the activity from which the user data must be emitted to be tracked.

ArgumentType

获取或设置要跟踪的用户数据的公共语言运行库 (CLR) 类型。Gets or sets the common language runtime (CLR) type of the user data to be tracked.

ArgumentTypeName

获取或设置要跟踪的用户数据的公共语言运行库 (CLR) 类型的非限定名称。Gets or sets the unqualified name of the common language runtime (CLR) type of the user data to be tracked.

Conditions

获取一个条件集合,这些条件用于限定必须从中发出要跟踪的用户数据的活动。Gets a collection of conditions that are used to qualify the activity from which the user data must be emitted to be tracked.

KeyName

获取或设置名称,用户数据必须与该名称关联才能使 UserTrackingLocation 得以匹配。Gets or sets the name with which the user data must be associated for the UserTrackingLocation to be matched.

MatchDerivedActivityTypes

获取或设置一个值,该值指定在从派生自活动类型(由 ActivityTypeActivityTypeName 指定)的活动中发出用户数据时,是否应对用户数据进行跟踪。Gets or sets a value that indicates whether the user data should be tracked when it is emitted from activities derived from the activity type specified by ActivityType or ActivityTypeName.

MatchDerivedArgumentTypes

可以通过用户跟踪位置来筛选用户跟踪的数据。The User tracking location is a way to filter user tracked data. 通过指定 ArgumentTypeArgumentTypeName,用户可以按用户跟踪数据的类型进行筛选。The user can filter by the type of the user tracked data by specifying the ArgumentType or ArgumentTypeName. 如果将 MatchDerivedArgumentTypes 设置为 true,则指定用户跟踪的数据可以为 ArgumentType/ArgumentTypeName 类型,或者是派生自 ArgumentType/ArgumentTypeName 的类型。Setting the MatchDerivedArgumentTypes to true specifies that the user tracked data can be of type ArgumentType/ArgumentTypeName or a type derived from the ArgumentType/ArgumentTypeName.

方法

Equals(Object)

确定指定的对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(继承自 Object)
GetHashCode()

用作默认哈希函数。Serves as the default hash function.

(继承自 Object)
GetType()

获取当前实例的 TypeGets the Type of the current instance.

(继承自 Object)
MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(继承自 Object)
ToString()

返回一个表示当前对象的 string。Returns a string that represents the current object.

(继承自 Object)

适用于