From c4085042dc486073d7857a369135e0a3c289b16c Mon Sep 17 00:00:00 2001 From: Ian Scaltritti Date: Fri, 4 Sep 2020 17:09:38 -0300 Subject: [PATCH 1/7] Adds missing doc to Root --- .../ActionChangeList.cs | 21 ++++ .../ActionState.cs | 23 ++++ .../AdaptiveComponentRegistration.cs | 17 +++ .../AdaptiveDialog.cs | 108 ++++++++++++++++++ .../AdaptiveDialogState.cs | 12 ++ .../AdaptiveEvents.cs | 3 + .../EntityAssignment.cs | 4 + .../EntityAssignmentComparer.cs | 6 + .../EntityInfo.cs | 4 + .../JsonExtensions.cs | 9 ++ .../LGResourceLoader.cs | 5 + .../LanguageGeneratorExtensions.cs | 3 + .../LanguagePolicy.cs | 11 +- .../PropertySchema.cs | 4 + .../ResourceExtensions.cs | 3 + .../TelemetryExtensions.cs | 3 + 16 files changed, 234 insertions(+), 2 deletions(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionChangeList.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionChangeList.cs index 9bc2f0527b..dd61e3c409 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionChangeList.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionChangeList.cs @@ -7,17 +7,38 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Defines the action state change list. + /// [DebuggerDisplay("{ChangeType}:{Desire}")] public class ActionChangeList { + /// + /// Gets or sets the action change type value. + /// + /// + /// Action change type value. + /// [JsonProperty(PropertyName = "changeType")] public ActionChangeType ChangeType { get; set; } = ActionChangeType.InsertActions; + /// + /// Gets or sets the list. + /// + /// + /// list. + /// [JsonProperty(PropertyName = "actions")] #pragma warning disable CA2227 // Collection properties should be read only (we can't change this without breaking binary compat) public List Actions { get; set; } = new List(); #pragma warning restore CA2227 // Collection properties should be read only + /// + /// Gets or sets the tag list. + /// + /// + /// Tag list. + /// [JsonProperty(PropertyName = "tags")] #pragma warning disable CA2227 // Collection properties should be read only (we can't change this without breaking binary compat) public List Tags { get; set; } = new List(); diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionState.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionState.cs index 6616f8c76d..5bb077a418 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionState.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ActionState.cs @@ -6,22 +6,45 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Contains state information about the action. + /// [DebuggerDisplay("{DialogId}")] public class ActionState : DialogState { + /// + /// Initializes a new instance of the class. + /// public ActionState() { } + /// + /// Initializes a new instance of the class. + /// + /// Optional, dialog identifier value. + /// Optional, dialog options. public ActionState(string dialogId = null, object options = null) { DialogId = dialogId; Options = options; } + /// + /// Gets or sets DialogId value. + /// + /// + /// DialogId value. + /// [JsonProperty(PropertyName = "dialogId")] public string DialogId { get; set; } + /// + /// Gets or sets options value. + /// + /// + /// Options value. + /// [JsonProperty(PropertyName = "options")] public object Options { get; set; } } diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveComponentRegistration.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveComponentRegistration.cs index 460faca91c..bce2c0ece5 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveComponentRegistration.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveComponentRegistration.cs @@ -24,8 +24,14 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// implementation for adaptive components. + /// public class AdaptiveComponentRegistration : ComponentRegistration, IComponentDeclarativeTypes { + /// + /// Initializes a new instance of the class. + /// public AdaptiveComponentRegistration() { // adaptive dialog functions @@ -34,6 +40,11 @@ public AdaptiveComponentRegistration() Expression.Functions.Add(HasPendingActionsFunction.Name, new HasPendingActionsFunction()); } + /// + /// Gets adaptive resources. + /// + /// with expected path to get all schema resources. + /// Adaptive resources. public virtual IEnumerable GetDeclarativeTypes(ResourceExplorer resourceExplorer) { // Conditionals @@ -172,6 +183,12 @@ public virtual IEnumerable GetDeclarativeTypes(ResourceExplorer } } + /// + /// Gets adaptive resources. + /// + /// ResourceExplorer to use to resolve references. + /// SourceContext to build debugger source map. + /// Adaptive resources. public virtual IEnumerable GetConverters(ResourceExplorer resourceExplorer, SourceContext sourceContext) { yield return new InterfaceConverter(resourceExplorer, sourceContext); diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs index 4791a6a304..fbd99d5529 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs @@ -27,6 +27,9 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive /// public class AdaptiveDialog : DialogContainer, IDialogDependencies { + /// + /// Class identifier. + /// [JsonProperty("$kind")] public const string Kind = "Microsoft.AdaptiveDialog"; @@ -52,6 +55,12 @@ public class AdaptiveDialog : DialogContainer, IDialogDependencies private SchemaHelper dialogSchema; + /// + /// Initializes a new instance of the class. + /// + /// Optioonal, dialog identifier. + /// Optional, source file full path. + /// Optional, line number in source file. public AdaptiveDialog(string dialogId = null, [CallerFilePath] string callerPath = "", [CallerLineNumber] int callerLine = 0) : base(dialogId) { @@ -135,6 +144,14 @@ public JObject Schema } } + /// + /// Called when the dialog is started and pushed onto the dialog stack. + /// + /// The for the current turn of conversation. + /// Optional, initial information to pass to the dialog. + /// Optional, a that can be used by other objects + /// or threads to receive notice of cancellation. + /// A representing the asynchronous operation. public override async Task BeginDialogAsync(DialogContext dc, object options = null, CancellationToken cancellationToken = default) { if (options is CancellationToken) @@ -206,6 +223,14 @@ public override async Task BeginDialogAsync(DialogContext dc, return await ContinueActionsAsync(dc, options, cancellationToken: cancellationToken).ConfigureAwait(false); } + /// + /// Called when the dialog is _continued_, where it is the active dialog and the + /// user replies with a new activity. + /// + /// The for the current turn of conversation. + /// Optional, a that can be used by other objects + /// or threads to receive notice of cancellation. + /// A representing the asynchronous operation. public override async Task ContinueDialogAsync(DialogContext dc, CancellationToken cancellationToken = default) { EnsureDependenciesInstalled(); @@ -216,6 +241,16 @@ public override async Task ContinueDialogAsync(DialogContext d return await ContinueActionsAsync(dc, options: null, cancellationToken).ConfigureAwait(false); } + /// + /// Called when a child dialog completed this turn, returning control to this dialog. + /// + /// The dialog context for the current turn of the conversation. + /// Reason why the dialog resumed. + /// Optional, value returned from the dialog that was called. The type + /// of the value returned is dependent on the child dialog. + /// Optional, A that can be used by other objects + /// or threads to receive notice of cancellation. + /// A representing the asynchronous operation. public override async Task ResumeDialogAsync(DialogContext dc, DialogReason reason, object result = null, CancellationToken cancellationToken = default) { if (result is CancellationToken) @@ -235,6 +270,15 @@ public override async Task ResumeDialogAsync(DialogContext dc, return EndOfTurn; } + /// + /// Called when the dialog is ending. + /// + /// The context object for this turn. + /// State information associated with the instance of this dialog on the dialog stack. + /// Reason why the dialog ended. + /// Optional, a that can be used by other objects + /// or threads to receive notice of cancellation. + /// A representing the asynchronous operation. public override Task EndDialogAsync(ITurnContext turnContext, DialogInstance instance, DialogReason reason, CancellationToken cancellationToken = default) { var properties = new Dictionary() @@ -277,6 +321,11 @@ public virtual async Task RepromptDialogAsync(DialogContext dc, DialogInstance i } } + /// + /// Creates a child for the given context. + /// + /// The for the current turn of conversation. + /// The child or null if no are found for the given context. public override DialogContext CreateChildContext(DialogContext dc) { var activeDialogState = dc.ActiveDialog.State as Dictionary; @@ -298,6 +347,10 @@ public override DialogContext CreateChildContext(DialogContext dc) return null; } + /// + /// Gets enumerated dependencies. + /// + /// enumerated dependencies. public IEnumerable GetDependencies() { EnsureDependenciesInstalled(); @@ -305,6 +358,10 @@ public IEnumerable GetDependencies() yield break; } + /// + /// Gets the internal version string. + /// + /// Internal version string. protected override string GetInternalVersion() { StringBuilder sb = new StringBuilder(); @@ -327,6 +384,13 @@ protected override string GetInternalVersion() return StringUtils.Hash(sb.ToString()); } + /// + /// Called before an event is bubbled to its parent. + /// + /// The for the current turn of conversation. + /// The being raised. + /// Optional, the for the task. + /// Whether the event is handled by the current dialog and further processing should stop. protected override async Task OnPreBubbleEventAsync(DialogContext dc, DialogEvent dialogEvent, CancellationToken cancellationToken = default) { var actionContext = ToActionContext(dc); @@ -335,6 +399,13 @@ protected override async Task OnPreBubbleEventAsync(DialogContext dc, Dial return await ProcessEventAsync(actionContext, dialogEvent, preBubble: true, cancellationToken: cancellationToken).ConfigureAwait(false); } + /// + /// Called after an event was bubbled to all parents and wasn't handled. + /// + /// The for the current turn of conversation. + /// The being raised. + /// Optional, the for the task. + /// Whether the event is handled by the current dialog and further processing should stop. protected override async Task OnPostBubbleEventAsync(DialogContext dc, DialogEvent dialogEvent, CancellationToken cancellationToken = default) { var actionContext = ToActionContext(dc); @@ -343,6 +414,14 @@ protected override async Task OnPostBubbleEventAsync(DialogContext dc, Dia return await ProcessEventAsync(actionContext, dialogEvent, preBubble: false, cancellationToken: cancellationToken).ConfigureAwait(false); } + /// + /// Event processing implementation. + /// + /// The for the current turn of conversation. + /// The being raised. + /// A flag indicator for preBubble processing. + /// Optional, a used to signal this operation should be cancelled. + /// A representation of a boolean indicator or the result. protected virtual async Task ProcessEventAsync(ActionContext actionContext, DialogEvent dialogEvent, bool preBubble, CancellationToken cancellationToken = default(CancellationToken)) { // Save into turn @@ -544,6 +623,13 @@ protected override async Task OnPostBubbleEventAsync(DialogContext dc, Dia return handled; } + /// + /// Waits for pending actions to complete and moves on to . + /// + /// The for the current turn of conversation. + /// Options used in evaluation. + /// Optional, the for the task. + /// A representation of . protected async Task ContinueActionsAsync(DialogContext dc, object options, CancellationToken cancellationToken) { if (options is CancellationToken) @@ -639,6 +725,12 @@ protected virtual void OnSetScopedServices(DialogContext dialogContext) } } + /// + /// Removes the current most action from the given if there are any. + /// + /// The for the current turn of conversation. + /// Optional, a that can be used by other objects. + /// A representing a boolean indicator for the result. #pragma warning disable CA1801 // Review unused parameters (we can't remove the cancellationToken parameter withoutt breaking binary compat). protected Task EndCurrentActionAsync(ActionContext actionContext, CancellationToken cancellationToken = default) #pragma warning restore CA1801 // Review unused parameters @@ -651,6 +743,12 @@ protected Task EndCurrentActionAsync(ActionContext actionContext, Cancella return Task.FromResult(false); } + /// + /// Called when the dialog's action ends, finishes turn. + /// + /// The for the current turn of conversation. + /// Optional, a that can be used by other objects. + /// A representation of . protected async Task OnEndOfActionsAsync(ActionContext actionContext, CancellationToken cancellationToken = default) { // Is the current dialog still on the stack? @@ -676,6 +774,13 @@ protected async Task OnEndOfActionsAsync(ActionContext actionC return new DialogTurnResult(DialogTurnStatus.Cancelled); } + /// + /// Recognizes intent for current activity given the class recognizer set, if set is null no intent will be recognized. + /// + /// The for the current turn of conversation. + /// to recognize. + /// Optional, a for the task. + /// A representing a . protected async Task OnRecognizeAsync(ActionContext actionContext, Activity activity, CancellationToken cancellationToken = default) { if (Recognizer != null) @@ -724,6 +829,9 @@ protected async Task OnRecognizeAsync(ActionContext actionCont }; } + /// + /// Ensures all dependencies for the class are installed. + /// protected virtual void EnsureDependenciesInstalled() { if (!installedDependencies) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialogState.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialogState.cs index 70c15346b3..537beb55e0 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialogState.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialogState.cs @@ -6,12 +6,24 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Defines adaptive dialog list. + /// public class AdaptiveDialogState { + /// + /// Initializes a new instance of the class. + /// public AdaptiveDialogState() { } + /// + /// Gets or sets list. + /// + /// + /// list. + /// [JsonProperty(PropertyName = "actions")] #pragma warning disable CA2227 // Collection properties should be read only (we can't change this without breaking binary compat) public List Actions { get; set; } = new List(); diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveEvents.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveEvents.cs index 54e9d877b2..bf51b6b782 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveEvents.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveEvents.cs @@ -3,6 +3,9 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Adaptive event identifier definition list. + /// public class AdaptiveEvents : DialogEvents { /// diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignment.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignment.cs index e81da5386e..e546360914 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignment.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignment.cs @@ -91,6 +91,10 @@ public void AddAlternatives(IEnumerable alternatives) } } + /// + /// Returns a string that represents the current object. + /// + /// A string that represents the current object. public override string ToString() => (IsExpected ? "+" : string.Empty) + $"{Event}: {Property} = {Operation}({Entity})"; } diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignmentComparer.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignmentComparer.cs index b4745780bc..c7977464fb 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignmentComparer.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityAssignmentComparer.cs @@ -31,6 +31,12 @@ public EntityAssignmentComparer(string[] operations) operationPreference = operations; } + /// + /// Compares x against y to determine its relative priority. + /// + /// Reference Entity. + /// Comparisson Entity. + /// Numerical value representing x's relative priority. public override int Compare(EntityAssignment x, EntityAssignment y) { // Order by event diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityInfo.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityInfo.cs index 09559b20c9..31e31de358 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityInfo.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/EntityInfo.cs @@ -126,6 +126,10 @@ public bool Alternative(EntityInfo entity) public bool Covers(EntityInfo entity) => (entity == this || entity.RootEntity != RootEntity) && Start <= entity.Start && End >= entity.End && End - Start > entity.End - entity.Start; + /// + /// Returns a string that represents the current object. + /// + /// A string that represents the current object. public override string ToString() => $"{Operation}({Name}:{Value}) P{Priority} {Score} {Coverage}"; diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/JsonExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/JsonExtensions.cs index 41142fc25b..b1e466635e 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/JsonExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/JsonExtensions.cs @@ -9,8 +9,17 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Implements JSON extensions. + /// public static class JsonExtensions { + /// + /// Removes first element of a queue. + /// + /// Element type. + /// List from where to remove first element. + /// Element removed. public static T Dequeue(this List queue) { var result = default(T); diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LGResourceLoader.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LGResourceLoader.cs index 1bfb7c877c..d87534585e 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LGResourceLoader.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LGResourceLoader.cs @@ -15,6 +15,11 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive.Generators public class LGResourceLoader #pragma warning restore CA1052 // Static holder types should be Static or NotInheritable { + /// + /// Groups locales from a given resource path. + /// + /// for the path to group. + /// Dictionary of grouped locale. public static Dictionary> GroupByLocale(ResourceExplorer resourceExplorer) { var resourceMapping = new Dictionary>(); diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs index adcc767c1e..0e35bba507 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs @@ -9,6 +9,9 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Implements language generator extensions. + /// public static class LanguageGeneratorExtensions { private static Dictionary languageGeneratorManagers = new Dictionary(); diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguagePolicy.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguagePolicy.cs index 8ec4838b69..2f10cad46e 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguagePolicy.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguagePolicy.cs @@ -12,13 +12,20 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive /// Language policy with fallback for each language as most specific to default en-us -> en -> default. /// public class LanguagePolicy : Dictionary - { - // Keep this method for JSON deserialization + { + /// + /// Initializes a new instance of the class. + /// + // Keep this method for JSON deserialization public LanguagePolicy() : base(DefaultPolicy(), StringComparer.OrdinalIgnoreCase) { } + /// + /// Initializes a new instance of the class. + /// + /// Default language to use. public LanguagePolicy(params string[] defaultLanguage) : base(DefaultPolicy(defaultLanguage), StringComparer.OrdinalIgnoreCase) { diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/PropertySchema.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/PropertySchema.cs index b7318ef169..5467bc5cca 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/PropertySchema.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/PropertySchema.cs @@ -127,6 +127,10 @@ public PropertySchema(string path, JObject schema, List children /// public IReadOnlyList Children { get; } + /// + /// Returns a string that represents the current object. + /// + /// A string that represents the current object. public override string ToString() => $"PropertySchema({Path})"; } } diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs index c41083efcd..389408ed4d 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs @@ -9,6 +9,9 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Implements resource extensions. + /// public static class ResourceExtensions { /// diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs index 14aa0ff6f0..00a4a1a157 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs @@ -3,6 +3,9 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { + /// + /// Implements telemetry extensions. + /// public static class TelemetryExtensions { /// From 9a0489078a7c61a383516d810657bdce2945a561 Mon Sep 17 00:00:00 2001 From: Ian Scaltritti Date: Fri, 4 Sep 2020 17:11:49 -0300 Subject: [PATCH 2/7] Removes CS1591 from NoWarn PropertyGroup --- .../Microsoft.Bot.Builder.Dialogs.Adaptive.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj index 7dead1ba6f..df1223a781 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj @@ -28,7 +28,7 @@ - $(NoWarn);CS1591;SX1309;CA2225 + $(NoWarn);SX1309;CA2225 From 4c68af33ccd93e6e952c1e83af7031bc79b9530c Mon Sep 17 00:00:00 2001 From: Santiago Grangetto Date: Fri, 4 Sep 2020 17:43:14 -0300 Subject: [PATCH 3/7] Remove comment about removing doc warn --- .../Microsoft.Bot.Builder.Dialogs.Adaptive.csproj | 1 - 1 file changed, 1 deletion(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj index df1223a781..160cd0fa4d 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Microsoft.Bot.Builder.Dialogs.Adaptive.csproj @@ -24,7 +24,6 @@ - From d89b4d0cc3cf27bd8e8c833bd22d2cb05a344f63 Mon Sep 17 00:00:00 2001 From: Ian Scaltritti Date: Mon, 7 Sep 2020 16:52:11 -0300 Subject: [PATCH 4/7] Minor corrections and improvements --- .../AdaptiveDialog.cs | 6 +++--- .../LanguageGeneratorExtensions.cs | 2 +- .../ResourceExtensions.cs | 2 +- .../TelemetryExtensions.cs | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs index fbd99d5529..9dd28eff47 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs @@ -58,7 +58,7 @@ public class AdaptiveDialog : DialogContainer, IDialogDependencies /// /// Initializes a new instance of the class. /// - /// Optioonal, dialog identifier. + /// Optional, dialog identifier. /// Optional, source file full path. /// Optional, line number in source file. public AdaptiveDialog(string dialogId = null, [CallerFilePath] string callerPath = "", [CallerLineNumber] int callerLine = 0) @@ -242,7 +242,7 @@ public override async Task ContinueDialogAsync(DialogContext d } /// - /// Called when a child dialog completed this turn, returning control to this dialog. + /// Called when a child dialog completed its turn, returning control to this dialog. /// /// The dialog context for the current turn of the conversation. /// Reason why the dialog resumed. @@ -744,7 +744,7 @@ protected Task EndCurrentActionAsync(ActionContext actionContext, Cancella } /// - /// Called when the dialog's action ends, finishes turn. + /// Awaits for completed actions to finish processing entity assignments and finishes turn. /// /// The for the current turn of conversation. /// Optional, a that can be used by other objects. diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs index 0e35bba507..9a863c8f29 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGeneratorExtensions.cs @@ -10,7 +10,7 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { /// - /// Implements language generator extensions. + /// Implements extension methods for language generator. /// public static class LanguageGeneratorExtensions { diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs index 389408ed4d..72788d8d56 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/ResourceExtensions.cs @@ -10,7 +10,7 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { /// - /// Implements resource extensions. + /// Implements extension methods for resource explorer. /// public static class ResourceExtensions { diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs index 00a4a1a157..b571c6baf6 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TelemetryExtensions.cs @@ -4,7 +4,7 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive { /// - /// Implements telemetry extensions. + /// Implements extension methods for telemetry. /// public static class TelemetryExtensions { From ce6b49fbffe4ae4b9bd80f72075964345600a15c Mon Sep 17 00:00:00 2001 From: Ian Scaltritti Date: Mon, 7 Sep 2020 17:36:09 -0300 Subject: [PATCH 5/7] Consistency fix --- .../AdaptiveDialog.cs | 8 ++++---- .../LanguageGenerator.cs | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs index 9dd28eff47..d3878e48c6 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/AdaptiveDialog.cs @@ -389,7 +389,7 @@ protected override string GetInternalVersion() /// /// The for the current turn of conversation. /// The being raised. - /// Optional, the for the task. + /// Optional, the that can be used by other objects or threads to receive notice of cancellation. /// Whether the event is handled by the current dialog and further processing should stop. protected override async Task OnPreBubbleEventAsync(DialogContext dc, DialogEvent dialogEvent, CancellationToken cancellationToken = default) { @@ -404,7 +404,7 @@ protected override async Task OnPreBubbleEventAsync(DialogContext dc, Dial /// /// The for the current turn of conversation. /// The being raised. - /// Optional, the for the task. + /// Optional, the that can be used by other objects or threads to receive notice of cancellation. /// Whether the event is handled by the current dialog and further processing should stop. protected override async Task OnPostBubbleEventAsync(DialogContext dc, DialogEvent dialogEvent, CancellationToken cancellationToken = default) { @@ -628,7 +628,7 @@ protected override async Task OnPostBubbleEventAsync(DialogContext dc, Dia /// /// The for the current turn of conversation. /// Options used in evaluation. - /// Optional, the for the task. + /// Optional, the that can be used by other objects or threads to receive notice of cancellation. /// A representation of . protected async Task ContinueActionsAsync(DialogContext dc, object options, CancellationToken cancellationToken) { @@ -779,7 +779,7 @@ protected async Task OnEndOfActionsAsync(ActionContext actionC /// /// The for the current turn of conversation. /// to recognize. - /// Optional, a for the task. + /// Optional, a that can be used by other objects or threads to receive notice of cancellation. /// A representing a . protected async Task OnRecognizeAsync(ActionContext actionContext, Activity activity, CancellationToken cancellationToken = default) { diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs index 6a919e925e..ae34db8144 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs @@ -17,7 +17,7 @@ public abstract class LanguageGenerator /// dialogContext. /// template or [templateId]. /// data to bind to. - /// the for the task. + /// the that can be used by other objects or threads to receive notice of cancellation. /// object or text. #pragma warning disable CA1716 // Identifiers should not match keywords (we can't change the template parameter name without breaking binary compat). public abstract Task GenerateAsync(DialogContext dialogContext, string template, object data, CancellationToken cancellationToken = default); From 46629c0ee4e68b5e7e59503e2c1f57e7f8c77783 Mon Sep 17 00:00:00 2001 From: Ian Scaltritti Date: Tue, 8 Sep 2020 17:23:24 -0300 Subject: [PATCH 6/7] Revert description change --- .../Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs index ae34db8144..6a919e925e 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/LanguageGenerator.cs @@ -17,7 +17,7 @@ public abstract class LanguageGenerator /// dialogContext. /// template or [templateId]. /// data to bind to. - /// the that can be used by other objects or threads to receive notice of cancellation. + /// the for the task. /// object or text. #pragma warning disable CA1716 // Identifiers should not match keywords (we can't change the template parameter name without breaking binary compat). public abstract Task GenerateAsync(DialogContext dialogContext, string template, object data, CancellationToken cancellationToken = default); From 76581827800aeca86227061fcd138220ccd18f5e Mon Sep 17 00:00:00 2001 From: Joel Mut Date: Tue, 22 Sep 2020 11:00:03 -0300 Subject: [PATCH 7/7] Add OnInstallationUpdateActivity documentation comments --- .../Activities/OnInstallationUpdateActivity.cs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TriggerConditions/Activities/OnInstallationUpdateActivity.cs b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TriggerConditions/Activities/OnInstallationUpdateActivity.cs index 3457953369..9a2c1f5a34 100644 --- a/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TriggerConditions/Activities/OnInstallationUpdateActivity.cs +++ b/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/TriggerConditions/Activities/OnInstallationUpdateActivity.cs @@ -13,9 +13,19 @@ namespace Microsoft.Bot.Builder.Dialogs.Adaptive.Conditions /// public class OnInstallationUpdateActivity : OnActivity { + /// + /// Class identifier. + /// [JsonProperty("$kind")] public new const string Kind = "Microsoft.OnInstallationUpdateActivity"; - + + /// + /// Initializes a new instance of the class. + /// + /// Optional, actions to add to the plan when the rule constraints are met. + /// Optional, condition which needs to be met for the actions to be executed. + /// Optional, source file full path. + /// Optional, line number in source file. [JsonConstructor] public OnInstallationUpdateActivity(List actions = null, string condition = null, [CallerFilePath] string callerPath = "", [CallerLineNumber] int callerLine = 0) : base(type: ActivityTypes.InstallationUpdate, actions: actions, condition: condition, callerPath: callerPath, callerLine: callerLine)