public static ISpeechletResponseBuilder DialogElicitSlot(this ISpeechletResponseBuilder builder, string slotName, Intent updatedIntent = null, string speech = null) { return(string.IsNullOrEmpty(speech) ? builder.DialogDelegate(updatedIntent) : builder.WithDialogDirective <DialogElicitSlotDirective>(updatedIntent, x => x.SlotToElicit = slotName).Say(speech)); }
public static ISpeechletResponseBuilder DialogConfirmIntent(this ISpeechletResponseBuilder builder, Intent updatedIntent = null, string speech = null) { return(string.IsNullOrEmpty(speech) ? builder.DialogDelegate(updatedIntent) : builder.WithDialogDirective <DialogConfirmIntentDirective>(updatedIntent).Say(speech)); }
public static ISpeechletResponseBuilder WithAskForPermissionsConsentCard(this ISpeechletResponseBuilder builder, IEnumerable <string> permissions) { return(builder.WithCard(new AskForPermissionsConsentCard { Permissions = permissions })); }
public static ISpeechletResponseBuilder WithSimpleCard(this ISpeechletResponseBuilder builder, string title, string content) { return(builder.WithCard(new SimpleCard { Content = content, Title = title })); }
public static ISpeechletResponseBuilder WithStandardCard(this ISpeechletResponseBuilder builder, string title, string text, Image image) { return(builder.WithCard(new StandardCard { Text = text, Title = title, Image = image })); }
private static ISpeechletResponseBuilder WithDialogDirective <T>(this ISpeechletResponseBuilder builder, Intent updatedIntent, Action <T> initialize = null) where T : DialogDirective, new() { var directive = new T { UpdatedIntent = updatedIntent }; initialize?.Invoke(directive); return(builder.KeepSession().WithDirective(directive)); }
public IntentHandler(ISpeechletResponseBuilder responseBuilder, ILogHelper logHelper) { this.responseBuilder = responseBuilder; this.logHelper = logHelper; }
public static ISpeechletResponseBuilder DialogDelegate(this ISpeechletResponseBuilder builder, Intent updatedIntent = null) { return(builder.WithDialogDirective <DialogDelegateDirective>(updatedIntent)); }
public SampleIntent1Handler(ISpeechletResponseBuilder responseBuilder, ILogHelper logHelper) : base(responseBuilder, logHelper) { }
public static ISpeechletResponseBuilder WithLinkAccountCard(this ISpeechletResponseBuilder builder) { return(builder.WithCard(new LinkAccountCard())); }
public DefaultHandler(ISpeechletResponseBuilder responseBuilder, ILogHelper logHelper) : base(responseBuilder, logHelper) { }