DialogStateManager Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The DialogStateManager manages memory scopes and pathresolvers MemoryScopes are named root level objects, which can exist either in the dialogcontext or off of turn state PathResolvers allow for shortcut behavior for mapping things like $foo -> dialog.foo.
public class DialogStateManager : System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string,object>>, System.Collections.Generic.IDictionary<string,object>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string,object>>
type DialogStateManager = class
interface IDictionary<string, obj>
interface ICollection<KeyValuePair<string, obj>>
interface seq<KeyValuePair<string, obj>>
interface IEnumerable
Public Class DialogStateManager
Implements ICollection(Of KeyValuePair(Of String, Object)), IDictionary(Of String, Object), IEnumerable(Of KeyValuePair(Of String, Object))
- Inheritance
-
DialogStateManager
- Implements
-
ICollection<KeyValuePair<String,Object>> ICollection<KeyValuePair<TKey,TValue>> IDictionary<String,Object> IEnumerable<KeyValuePair<String,Object>> IEnumerable<KeyValuePair<TKey,TValue>> IEnumerable<T> IEnumerable
Constructors
DialogStateManager(DialogContext, DialogStateManagerConfiguration) |
Initializes a new instance of the DialogStateManager class. |
Properties
Configuration |
Gets or sets the configured path resolvers and memory scopes for the dialog state manager. |
Count |
Gets the number of memory scopes in the dialog state manager. |
IsReadOnly |
Gets a value indicating whether the dialog state manager is read-only. |
Item[String] |
Gets or sets the elements with the specified key. |
Keys |
Gets an ICollection<T> containing the keys of the memory scopes. |
Values |
Gets an ICollection<T> containing the values of the memory scopes. |
Methods
Add(KeyValuePair<String,Object>) |
Adds an item to the dialog state manager. |
Add(String, Object) |
Adds an element to the dialog state manager. |
AnyPathChanged(UInt32, IEnumerable<String>) |
Check to see if any path has changed since watermark. |
Clear() |
Removes all items from the dialog state manager. |
Contains(KeyValuePair<String,Object>) |
Determines whether the dialog state manager contains a specific value. |
ContainsKey(String) |
Determines whether the dialog state manager contains an element with the specified key. |
CopyTo(KeyValuePair<String,Object>[], Int32) |
Copies the elements of the dialog state manager to an array starting at a particular index. |
DeleteScopesMemoryAsync(String, CancellationToken) |
Delete the memory for a scope. |
GetBoolValue(String, Boolean) |
Get a bool value from memory using a path expression. |
GetEnumerator() |
Returns an enumerator that iterates through the collection. |
GetIntValue(String, Int32) |
Get a int value from memory using a path expression. |
GetMemoryScope(String) |
Get MemoryScope by name. |
GetMemorySnapshot() |
Gets all memoryscopes suitable for logging. |
GetStringValue(String, String) |
Get a string value from memory using a path expression. |
GetValue<T>(String, Func<T>) |
Get the value from memory using path expression (NOTE: This always returns clone of value). |
LoadAllScopesAsync(CancellationToken) |
Load all of the scopes. |
Remove(KeyValuePair<String,Object>) |
Removes the first occurrence of a specific object from the dialog state manager. |
Remove(String) |
Removes the element with the specified key from the dialog state manager. |
RemoveValue(String) |
Remove property from memory. |
ResolveMemoryScope(String, String) |
ResolveMemoryScope will find the MemoryScope for and return the remaining path. |
SaveAllChangesAsync(CancellationToken) |
Save all changes for all scopes. |
SetValue(String, Object) |
Set memory to value. |
TrackPaths(IEnumerable<String>) |
Track when specific paths are changed. |
TransformPath(String) |
Transform the path using the registered PathTransformers. |
TryGetValue(String, Object) |
Gets the value associated with the specified key. |
TryGetValue<T>(String, T) |
Get the value from memory using path expression (NOTE: This always returns clone of value). |
Version() |
Version help caller to identify the updates and decide cache or not. |
Explicit Interface Implementations
IEnumerable.GetEnumerator() |