Class DataChangeHelper
Namespace: Casewhere.Runtime.Api.Services
Assembly: Casewhere.Runtime.dll
public static class DataChangeHelper
Inheritance
Inherited Members
object.ToString(), object.Equals(object), object.Equals(object, object), object.ReferenceEquals(object, object), object.GetHashCode(), object.GetType(), object.MemberwiseClone()
Extension Methods
ObjectExtension.ConvertToBsonValue(object)
Methods
FindDataChanges(IDictionary<string, object>, IDictionary<string, object>, IList<DataAttribute>, bool)
public static IList<ValueChange> FindDataChanges(IDictionary<string, object> dataAfter, IDictionary<string, object> dataBefore = null, IList<DataAttribute> attributes = null, bool isNeedToConvertToBson = false)
Parameters
dataAfter
IDictionary<string, object>
dataBefore
IDictionary<string, object>
attributes
IList<DataAttribute>
isNeedToConvertToBson
bool
Returns
IList<ValueChange>
GetChanges(IDictionary<string, object>, IDictionary<string, object>, IList<DataAttribute>)
public static IDictionary<string, object> GetChanges(IDictionary<string, object> dataBefore, IDictionary<string, object> dataAfter, IList<DataAttribute> attributes)
Parameters
dataBefore
IDictionary<string, object>
dataAfter
IDictionary<string, object>
attributes
IList<DataAttribute>
Returns
HasValueChanged(object, object, DataAttribute)
public static bool HasValueChanged(object fromValue, object toValue, DataAttribute attribute)
Parameters
fromValue
object
toValue
object
attribute
DataAttribute
Returns
IsArrayPropertyHasValueChanged(object, object, DataAttribute)
public static bool IsArrayPropertyHasValueChanged(object fromValue, object toValue, DataAttribute attribute)
Parameters
fromValue
object
toValue
object
attribute
DataAttribute
Returns
IsDocumentPropertyHasValueChanged(object, object)
public static bool IsDocumentPropertyHasValueChanged(object fromValue, object toValue)
Parameters
fromValue
object
toValue
object
Returns
IsObjectPropertyHasValueChanged(object, object)
public static bool IsObjectPropertyHasValueChanged(object fromValue, object toValue)
Parameters
fromValue
object
toValue
object