Show / Hide Table of Contents

Class JsonExpando

An expando object created from a JSON.

Inheritance
System.Object
System.Dynamic.DynamicObject
ExpandoBase
Expando
JsonExpando
Implements
IExpando
System.Dynamic.IDynamicMetaObjectProvider
IIndexable
Inherited Members
ExpandoBase.Item[String]
ExpandoBase.GetDynamicMemberNames()
ExpandoBase.HasDynamicMember(String)
ExpandoBase.TryGetMember(GetMemberBinder, Object)
ExpandoBase.TrySetMember(SetMemberBinder, Object)
ExpandoBase.TryInvokeMember(InvokeMemberBinder, Object[], Object)
ExpandoBase.ToDictionary(Func<String, String>, Func<Object, Object>)
ExpandoBase.GetInnerObjectTypeInfo()
ExpandoBase.GetThisTypeInfo()
ExpandoBase.TrySetValue(String, Object)
System.Dynamic.DynamicObject.GetMetaObject(System.Linq.Expressions.Expression)
System.Dynamic.DynamicObject.TryBinaryOperation(System.Dynamic.BinaryOperationBinder, System.Object, System.Object)
System.Dynamic.DynamicObject.TryConvert(System.Dynamic.ConvertBinder, System.Object)
System.Dynamic.DynamicObject.TryCreateInstance(System.Dynamic.CreateInstanceBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TryDeleteIndex(System.Dynamic.DeleteIndexBinder, System.Object[])
System.Dynamic.DynamicObject.TryDeleteMember(System.Dynamic.DeleteMemberBinder)
System.Dynamic.DynamicObject.TryGetIndex(System.Dynamic.GetIndexBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TryInvoke(System.Dynamic.InvokeBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TrySetIndex(System.Dynamic.SetIndexBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TryUnaryOperation(System.Dynamic.UnaryOperationBinder, System.Object)
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Kephas.Serialization.ServiceStack.Text
Assembly: Kephas.Serialization.ServiceStack.Text.dll
Syntax
public class JsonExpando : Expando, IExpando, IDynamicMetaObjectProvider, IIndexable

Constructors

| Improve this Doc View Source

JsonExpando(IDictionary<String, Object>)

Initializes a new instance of the JsonExpando class.

Declaration
public JsonExpando(IDictionary<string, object> jsonHash)
Parameters
Type Name Description
System.Collections.Generic.IDictionary<System.String, System.Object> jsonHash

The json hash.

| Improve this Doc View Source

JsonExpando(String)

Initializes a new instance of the JsonExpando class.

Declaration
public JsonExpando(string json)
Parameters
Type Name Description
System.String json

The JSON.

Methods

| Improve this Doc View Source

ToString()

Returns a string that represents the current object.

Declaration
public override string ToString()
Returns
Type Description
System.String

A string that represents the current object.

Overrides
System.Object.ToString()
| Improve this Doc View Source

TryConvertToJsonExpando(Object)

Tries to convert the provided object to a JsonExpando.

Declaration
protected static object TryConvertToJsonExpando(object obj)
Parameters
Type Name Description
System.Object obj

The object.

Returns
Type Description
System.Object

A JsonExpando object, a list of JsonExpando objects, or the original object, if the object could not be converted.

| Improve this Doc View Source

TryGetValue(String, out Object)

Attempts to get the dynamic value with the given key.

Declaration
protected override bool TryGetValue(string key, out object value)
Parameters
Type Name Description
System.String key

The key.

System.Object value

The value to get.

Returns
Type Description
System.Boolean

true if a value is found, false otherwise.

Overrides
ExpandoBase.TryGetValue(String, out Object)
Remarks

First of all, it is tried to get a property value from the inner object, if one is set. The next try is to retrieve the property value from the expando object itself. Lastly, if still a property by the provided name cannot be found, the inner dictionary is searched by the provided key.

Implements

IExpando
System.Dynamic.IDynamicMetaObjectProvider
IIndexable

Extension Methods

DynamicObjectExtensions.SetPropertyValue(Object, String, Object)
DynamicObjectExtensions.TrySetPropertyValue(Object, String, Object)
DynamicObjectExtensions.GetPropertyValue(Object, String)
DynamicObjectExtensions.TryGetPropertyValue(Object, String, out Object)
DynamicObjectExtensions.GetRuntimeTypeInfo(Object)
DynamicObjectExtensions.ToDynamic(Object)
DynamicObjectExtensions.ToExpando(Object)
BehaviorValue.ToBehaviorValue<TValue>(TValue)
CollectionExtensions.AddRange<T, TItem>(T, IEnumerable<TItem>)
LoggingExtensions.GetLogger(Object, IContext)
TypeExtensions.GetAbstractType(Object)
TypeExtensions.GetAbstractTypeInfo(Object)
ReflectionHelper.GetTypeInfo(Object)
EntityEntryExtensions.TryGetAttachedEntityEntry(Object)
  • Improve this Doc
  • View Source
Back to top Generated by DocFX