Activity 클래스
정의
활동은 봇 Framework 3.0 프로토콜에 대 한 기본 통신 유형입니다.An Activity is the basic communication type for the Bot Framework 3.0 protocol.
[System.Diagnostics.DebuggerDisplay("[{Type}] {Text ?? System.String.Empty}")]
public class Activity : Microsoft.Bot.Schema.IContactRelationUpdateActivity, Microsoft.Bot.Schema.IConversationUpdateActivity, Microsoft.Bot.Schema.IEndOfConversationActivity, Microsoft.Bot.Schema.IEventActivity, Microsoft.Bot.Schema.IHandoffActivity, Microsoft.Bot.Schema.IInstallationUpdateActivity, Microsoft.Bot.Schema.IInvokeActivity, Microsoft.Bot.Schema.IMessageDeleteActivity, Microsoft.Bot.Schema.IMessageReactionActivity, Microsoft.Bot.Schema.IMessageUpdateActivity, Microsoft.Bot.Schema.ISuggestionActivity, Microsoft.Bot.Schema.ITraceActivity, Microsoft.Bot.Schema.ITypingActivity
[<System.Diagnostics.DebuggerDisplay("[{Type}] {Text ?? System.String.Empty}")>]
type Activity = class
interface IActivity
interface IConversationUpdateActivity
interface IContactRelationUpdateActivity
interface IInstallationUpdateActivity
interface IMessageActivity
interface IMessageUpdateActivity
interface IMessageDeleteActivity
interface IMessageReactionActivity
interface ISuggestionActivity
interface ITypingActivity
interface IEndOfConversationActivity
interface IEventActivity
interface IInvokeActivity
interface ITraceActivity
interface IHandoffActivity
Public Class Activity
Implements IContactRelationUpdateActivity, IConversationUpdateActivity, IEndOfConversationActivity, IEventActivity, IHandoffActivity, IInstallationUpdateActivity, IInvokeActivity, IMessageDeleteActivity, IMessageReactionActivity, IMessageUpdateActivity, ISuggestionActivity, ITraceActivity, ITypingActivity
- 상속
-
Activity
- 특성
- 구현
-
IActivity IContactRelationUpdateActivity IConversationUpdateActivity IEndOfConversationActivity IEventActivity IHandoffActivity IInstallationUpdateActivity IInvokeActivity IMessageActivity IMessageDeleteActivity IMessageReactionActivity IMessageUpdateActivity ISuggestionActivity ITraceActivity ITypingActivity
설명
활동 클래스에는 개별 활동에 포함 될 수 있는 개별 속성이 모두 포함 됩니다.The Activity class contains all properties that individual, more specific activities could contain. 상위 집합 형식입니다.It is a superset type.
생성자
필드
ContentType |
미디어 유형 리소스를 식별 하는 HTTP |
속성
Action |
ContactRelationUpdate의 받는 사람이 보낸 사람의 연락처 목록에 추가 되었는지 아니면 제거 되었는지를 나타내는 문자열을 가져오거나 설정 합니다.Gets or sets a string indicating whether the recipient of a contactRelationUpdate was added to or removed from the sender's contact list. |
AttachmentLayout |
여러 첨부 파일의 레이아웃 힌트를 가져오거나 설정 합니다.Gets or sets the layout hint for multiple attachments. 기본값: list.Default: list. 가능한 값은에 의해 정의 됩니다 AttachmentLayoutTypes .Possible values are defined by AttachmentLayoutTypes. |
Attachments |
활동에 대 한 첨부 파일을 가져오거나 설정 합니다.Gets or sets the attachments for the activity. |
CallerId |
Bot의 호출자를 식별 하는 IRI를 포함 하는 문자열을 가져오거나 설정 합니다.Gets or sets a string containing an IRI identifying the caller of a bot. 이 필드는 유선을 통해 전송되는 것이 아니라 호출자의 ID(예: 토큰)를 어설션하는 암호화 확인 가능한 데이터를 기반으로 하여 봇과 클라이언트에서 채워집니다.This field is not intended to be transmitted over the wire, but is instead populated by bots and clients based on cryptographically verifiable data that asserts the identity of the callers (e.g. tokens). |
ChannelData |
채널 관련 콘텐츠를 가져오거나 설정 합니다.Gets or sets channel-specific content. |
ChannelId |
채널을 고유 하 게 식별 하는 ID를 가져오거나 설정 합니다.Gets or sets an ID that uniquely identifies the channel. 채널별로 설정합니다.Set by the channel. |
Code |
대화가 종료 된 이유를 나타내는 endOfConversation 작업에 대 한 코드를 가져오거나 설정 합니다.Gets or sets a code for endOfConversation activities that indicates why the conversation ended. 가능한 값은에 정의 되어 EndOfConversationCodes 있습니다.Possible values are defined in EndOfConversationCodes. |
Conversation |
활동이 속한 대화를 가져오거나 설정 합니다.Gets or sets the conversation to which the activity belongs. |
DeliveryMode |
활동의 수신자 대체 배달 경로에 신호를 보내는 배달 힌트를 가져오거나 설정 합니다.Gets or sets a delivery hint to signal to the recipient alternate delivery paths for the activity. 기본 배달 모드는 "default"입니다.The default delivery mode is "default". 가능한 값은에 정의 되어 DeliveryModes 있습니다.Possible values are defined in DeliveryModes. |
Entities |
메시지에 언급 된 엔터티를 가져오거나 설정 합니다.Gets or sets the entities that were mentioned in the message. |
Expiration |
활동이 "만료" 된 것으로 간주 되 고 받는 사람에 게 표시 되지 않아야 하는 시간을 가져오거나 설정 합니다.Gets or sets the time at which the activity should be considered to be "expired" and should not be presented to the recipient. |
From |
메시지의 보낸 사람을 가져오거나 설정 합니다.Gets or sets the sender of the message. |
HistoryDisclosed |
채널의 이전 기록이 공개 되는지 여부를 나타내는 값을 가져오거나 설정 합니다.Gets or sets a value indicating whether the prior history of the channel is disclosed. |
Id |
채널에서 작업을 고유 하 게 식별 하는 ID를 가져오거나 설정 합니다.Gets or sets an ID that uniquely identifies the activity on the channel. |
Importance |
활동의 중요도를 가져오거나 설정 합니다.Gets or sets the importance of the activity. 가능한 값은에 정의 되어 ActivityImportance 있습니다.Possible values are defined in ActivityImportance. |
InputHint |
메시지가 클라이언트에 전달 된 후 bot에서 사용자 입력을 수락, 예상 또는 무시 하는지 여부를 나타내는 문자열을 가져오거나 설정 합니다 (참조) InputHints .Gets or sets a string indicating whether your bot is accepting, expecting, or ignoring user input after the message is delivered to the client (see InputHints. |
Label |
활동에 대 한 설명 레이블을 가져오거나 설정 합니다.Gets or sets a descriptive label for the activity. |
ListenFor |
음성 및 언어 준비 시스템에서 수신 해야 하는 구와 참조의 목록을 가져오거나 설정 합니다.Gets or sets list of phrases and references that speech and language-priming systems should listen for. |
Locale |
텍스트 필드 내용의 BCP-47 로캘 이름을 가져오거나 설정 합니다.Gets or sets a BCP-47 locale name for the contents of the text field. |
LocalTimestamp |
메시지를 보낸 날짜와 시간을 ISO-8601 형식으로 표현 된 현지 시간으로 가져오거나 설정 합니다.Gets or sets the date and time when the message was sent, in local time, expressed in ISO-8601 format. 예를 들면 2016-09-23T13:07:49.4714686-07:00입니다.For example, 2016-09-23T13:07:49.4714686-07:00. |
LocalTimezone |
메시지의 현지 시간을 정의 하는 데 사용 되는 표준 시간대의 이름을 가져오거나 설정 합니다 .이는 IANA 표준 시간대 데이터베이스 형식으로 표현 됩니다.Gets or sets the name of the timezone used to define local time for the message, expressed in IANA Time Zone database format. 예를 들어 America/Los_Angeles와 같습니다.For example, America/Los_Angeles. |
MembersAdded |
대화에 추가 된 멤버의 컬렉션을 가져오거나 설정 합니다.Gets or sets the collection of members added to the conversation. |
MembersRemoved |
대화에서 제거 된 멤버의 컬렉션을 가져오거나 설정 합니다.Gets or sets the collection of members removed from the conversation. |
Name |
호출 또는 이벤트 활동과 관련 된 작업의 이름을 가져오거나 설정 합니다.Gets or sets the name of the operation associated with an invoke or event activity. |
Properties |
형식으로 정의 되지 Activity 않지만 serialize 된 REST JSON 개체에 나타날 수 있는 속성을 가져오거나 설정 합니다.Gets or sets properties that are not otherwise defined by the Activity type but that might appear in the serialized REST JSON object. |
ReactionsAdded |
대화에 추가 된 반응의 컬렉션을 가져오거나 설정 합니다.Gets or sets the collection of reactions added to the conversation. |
ReactionsRemoved |
대화에서 제거 된 반응의 컬렉션을 가져오거나 설정 합니다.Gets or sets the collection of reactions removed from the conversation. |
Recipient |
메시지의 수신자를 가져오거나 설정 합니다.Gets or sets the recipient of the message. |
RelatesTo |
ConversationReference다른 대화 또는 활동에 대 한를 가져오거나 설정 합니다.Gets or sets a ConversationReference to another conversation or activity. |
ReplyToId |
이 메시지가 회신 하는 메시지의 ID를 가져오거나 설정 합니다.Gets or sets the ID of the message to which this message is a reply. |
SemanticAction |
이 요청과 함께 제공 되는 선택적 프로그래밍 작업을 가져오거나 설정 합니다.Gets or sets an optional programmatic action accompanying this request. |
ServiceUrl |
채널의 서비스 끝점을 지정 하는 URL을 가져오거나 설정 합니다.Gets or sets the URL that specifies the channel's service endpoint. 채널별로 설정합니다.Set by the channel. |
Speak |
말할 텍스트를 가져오거나 설정 합니다.Gets or sets the text to speak. |
SuggestedActions |
작업에 대해 권장 되는 작업을 가져오거나 설정 합니다.Gets or sets the suggested actions for the activity. |
Summary |
채널에서 카드를 렌더링할 수 없는 경우 표시할 텍스트를 가져오거나 설정 합니다.Gets or sets the text to display if the channel cannot render cards. |
Text |
메시지의 텍스트 콘텐츠를 가져오거나 설정 합니다.Gets or sets the text content of the message. |
TextFormat |
텍스트 필드의 형식을 가져오거나 설정 합니다.Gets or sets the format of text fields. 기본값: markdown.Default: markdown. 가능한 값은에 의해 정의 됩니다 TextFormatTypes .Possible values are defined by TextFormatTypes. |
TextHighlights |
활동에 ReplyToId 값이 포함 된 경우 강조 표시할 텍스트 조각의 컬렉션을 가져오거나 설정 합니다.Gets or sets the collection of text fragments to highlight when the activity contains a ReplyToId value. |
Timestamp |
메시지가 전송 된 날짜 및 시간을 ISO-8601 형식으로 표현 된 UTC로 가져오거나 설정 합니다.Gets or sets the date and time when the message was sent, in UTC, expressed in ISO-8601 format. |
TopicName |
대화의 업데이트 된 항목 이름을 가져오거나 설정 합니다.Gets or sets the updated topic name of the conversation. |
Type |
작업 유형을 가져오거나 설정 합니다.Gets or sets the activity type. 가능한 값은 다음과 같습니다. ' message ', ' contactRelationUpdate ', ' conversationUpdate ', ' 입력 ', ' endOfConversation ', ' event ', ' invoke ', ' deleteUserData ', ' messageUpdate ', ' Messageupdate ', ' 설치 업데이트 ', ' messageReaction ', ' 제안 ', ' 추적 ', ' 전달 '.Possible values include: 'message', 'contactRelationUpdate', 'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData', 'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion', 'trace', 'handoff'. |
Value |
작업에 연결 된 값을 가져오거나 설정 합니다.Gets or sets a value that is associated with the activity. |
ValueType |
작업 값 개체의 형식을 가져오거나 설정 합니다.Gets or sets the type of the activity's value object. |
메서드
ApplyConversationReference(ConversationReference, Boolean) |
이 작업을 기존의 배달 정보로 업데이트 ConversationReference 합니다.Updates this activity with the delivery information from an existing ConversationReference. |
AsContactRelationUpdateActivity() |
이 활동을 개체로 반환 IContactRelationUpdateActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IContactRelationUpdateActivity object; or null, if this is not that type of activity. |
AsConversationUpdateActivity() |
이 활동을 개체로 반환 IConversationUpdateActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IConversationUpdateActivity object; or null, if this is not that type of activity. |
AsEndOfConversationActivity() |
이 활동을 개체로 반환 IEndOfConversationActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IEndOfConversationActivity object; or null, if this is not that type of activity. |
AsEventActivity() |
이 활동을 개체로 반환 IEventActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IEventActivity object; or null, if this is not that type of activity. |
AsHandoffActivity() |
이 활동을 개체로 반환 IHandoffActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IHandoffActivity object; or null, if this is not that type of activity. |
AsInstallationUpdateActivity() |
이 활동을 개체로 반환 IInstallationUpdateActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IInstallationUpdateActivity object; or null, if this is not that type of activity. |
AsInvokeActivity() |
이 활동을 개체로 반환 IInvokeActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IInvokeActivity object; or null, if this is not that type of activity. |
AsMessageActivity() |
이 활동을 개체로 반환 IMessageActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IMessageActivity object; or null, if this is not that type of activity. |
AsMessageDeleteActivity() |
이 활동을 개체로 반환 IMessageDeleteActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IMessageDeleteActivity object; or null, if this is not that type of activity. |
AsMessageReactionActivity() |
이 활동을 개체로 반환 IMessageReactionActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IMessageReactionActivity object; or null, if this is not that type of activity. |
AsMessageUpdateActivity() |
이 활동을 개체로 반환 IMessageUpdateActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an IMessageUpdateActivity object; or null, if this is not that type of activity. |
AsSuggestionActivity() |
이 활동을 개체로 반환 ISuggestionActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an ISuggestionActivity object; or null, if this is not that type of activity. |
AsTraceActivity() |
이 활동을 개체로 반환 ITraceActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an ITraceActivity object; or null, if this is not that type of activity. |
AsTypingActivity() |
이 활동을 개체로 반환 ITypingActivity 하거나, 해당 유형의 활동이 아닌 경우 null을 반환 합니다.Returns this activity as an ITypingActivity object; or null, if this is not that type of activity. |
CreateContactRelationUpdateActivity() |
클래스의 인스턴스를 Activity IContactRelationUpdateActivity 개체로 만듭니다.Creates an instance of the Activity class as an IContactRelationUpdateActivity object. |
CreateConversationUpdateActivity() |
클래스의 인스턴스를 Activity IConversationUpdateActivity 개체로 만듭니다.Creates an instance of the Activity class as an IConversationUpdateActivity object. |
CreateEndOfConversationActivity() |
클래스의 인스턴스를 Activity IEndOfConversationActivity 개체로 만듭니다.Creates an instance of the Activity class as an IEndOfConversationActivity object. |
CreateEventActivity() |
클래스의 인스턴스를 Activity IEventActivity 개체로 만듭니다.Creates an instance of the Activity class as an IEventActivity object. |
CreateHandoffActivity() |
클래스의 인스턴스를 Activity IHandoffActivity 개체로 만듭니다.Creates an instance of the Activity class as an IHandoffActivity object. |
CreateInvokeActivity() |
클래스의 인스턴스를 Activity IInvokeActivity 개체로 만듭니다.Creates an instance of the Activity class as an IInvokeActivity object. |
CreateMessageActivity() |
클래스의 인스턴스를 Activity IMessageActivity 개체로 만듭니다.Creates an instance of the Activity class as an IMessageActivity object. |
CreateReply(String, String) |
이 활동에 대 한 응답으로 새 메시지 활동을 만듭니다.Creates a new message activity as a response to this activity. |
CreateTrace(String, Object, String, String) |
이 활동을 기반으로 새 추적 활동을 만듭니다.Creates a new trace activity based on this activity. |
CreateTraceActivity(String, String, Object, String) |
클래스의 인스턴스를 Activity ITraceActivity 개체로 만듭니다.Creates an instance of the Activity class as an ITraceActivity object. |
CreateTypingActivity() |
클래스의 인스턴스를 Activity ITypingActivity 개체로 만듭니다.Creates an instance of the Activity class as an ITypingActivity object. |
GetChannelData<TypeT>() |
이 작업에 대 한 채널 데이터를 강력한 형식의 개체로 가져옵니다.Gets the channel data for this activity as a strongly-typed object. |
GetConversationReference() |
ConversationReference이 활동을 기반으로을 만듭니다.Creates a ConversationReference based on this activity. |
GetMentions() |
이 활동의 엔터티에서 멘 션을 확인 합니다.Resolves the mentions from the entities of this activity. |
GetReplyConversationReference(ResourceResponse) |
이 활동의 대화 정보를 기반으로 하는 ConversationReference와 활동을 보내는 ResourceResponse를 만듭니다.Create a ConversationReference based on this Activity's Conversation info and the ResourceResponse from sending an activity. |
HasContent() |
이 활동에 콘텐츠가 있는지 여부를 나타냅니다.Indicates whether this activity has content. |
IsActivity(String) |
이 작업이 지정 된 작업 유형 인지 여부를 나타냅니다.Indicates whether this activity is of a specified activity type. |
IsFromStreamingConnection() |
활동이 Http/Https 연결을 통해 전송 되었는지, 아니면 스트리밍을 통해이를 확인할 수 있습니다. ServiceUrl 속성을 살펴보면이를 확인할 수 있습니다. (1) http/https를 통해 메시지를 보내는 모든 채널은 스트리밍이 아닙니다 (2) 스트리밍을 통해 메시지를 보내는 채널은 Http/https로 시작 하지 않는 ServiceUrl을 포함 합니다.Determine if the Activity was sent via an Http/Https connection or Streaming This can be determined by looking at the ServiceUrl property: (1) All channels that send messages via http/https are not streaming (2) Channels that send messages via streaming have a ServiceUrl that does not begin with http/https. |
TryGetChannelData<TypeT>(TypeT) |
이 작업에 대 한 채널 데이터를 강력한 형식의 개체로 가져옵니다.Gets the channel data for this activity as a strongly-typed object. 반환 값은 작업의 성공 여부를 idicates 합니다.A return value idicates whether the operation succeeded. |
확장 메서드
TeamsGetChannelId(IActivity) |
현재 작업에서 팀의 채널 id를 가져옵니다.Gets the Team's channel id from the current activity. |
TeamsGetMeetingInfo(IActivity) |
현재 활동에서 TeamsMeetingInfo 개체를 가져옵니다.Gets the TeamsMeetingInfo object from the current activity. |
TeamsGetTeamInfo(IActivity) |
현재 활동에서 TeamsInfo 개체를 가져옵니다.Gets the TeamsInfo object from the current activity. |
TeamsNotifyUser(IActivity) |
팀 내에서 알림을 생성 하도록 현재 작업을 구성 합니다.Configures the current activity to generate a notification within Teams. |
TeamsNotifyUser(IActivity, Boolean, String) |
팀 내에서 알림을 생성 하도록 현재 작업을 구성 합니다.Configures the current activity to generate a notification within Teams. |
MentionsId(IMessageActivity, String) |
텍스트 속성에 Id를 언급 하 고 있습니다.Is there a mention of Id in the Text Property. |
MentionsRecipient(IMessageActivity) |
텍스트 속성에 Recipient.Id를 언급 하 고 있습니다.Is there a mention of Recipient.Id in the Text Property. |
RemoveMentionText(IMessageActivity, String) |
Activity. Text 속성에서 지정 된 id에 대 한 모든 언급 텍스트를 제거 합니다.Remove any mention text for given id from the Activity.Text property. 예를 들어 메시지 @echoBot Hi 봇에서 " @echoBot "를 제거 하 고 "Hi 봇"을 남겨 둡니다.For example, given the message @echoBot Hi Bot, this will remove "@echoBot", leaving "Hi Bot". |
RemoveRecipientMention(IMessageActivity) |
텍스트 속성에서 받는 사람 텍스트를 제거 합니다.Remove recipient mention text from Text property. 이 함수는 활동의 텍스트를 변경 하기 때문에 주의 해 서 사용 합니다.Use with caution because this function is altering the text on the Activity. |
GetLocale(IActivity) |
활동의 로캘을 가져옵니다.Gets the locale for the activity. |
SetLocale(IActivity, String) |
활동의 로캘을 설정 합니다.Sets the locale for the activity. |