Interface IExpando
Contract for dynamic objects allowing getting or setting properties by their name through an indexer.
Inherited Members
System.Dynamic.IDynamicMetaObjectProvider.GetMetaObject(System.Linq.Expressions.Expression)
Namespace: Kephas.Dynamic
Assembly: Kephas.Core.dll
Syntax
public interface IExpando : IDynamicMetaObjectProvider, IIndexable
Methods
| Improve this Doc View SourceHasDynamicMember(String)
Indicates whether the memberName
is defined in the expando.
Declaration
bool HasDynamicMember(string memberName)
Parameters
Type | Name | Description |
---|---|---|
System.String | memberName | Name of the member. |
Returns
Type | Description |
---|---|
System.Boolean | True if defined, false if not. |
ToDictionary(Func<String, String>, Func<Object, Object>)
Converts the expando to a dictionary having as keys the property names and as values the respective properties' values.
Declaration
IDictionary<string, object> ToDictionary(Func<string, string> keyFunc = null, Func<object, object> valueFunc = null)
Parameters
Type | Name | Description |
---|---|---|
System.Func<System.String, System.String> | keyFunc | The key transformation function (optional). |
System.Func<System.Object, System.Object> | valueFunc | The value transformation function (optional). |
Returns
Type | Description |
---|---|
System.Collections.Generic.IDictionary<System.String, System.Object> | A dictionary of property values with their associated names. |