/// <summary> /// Sets the row action (state) to one of <see cref="DBRowState"/> values. /// </summary> /// <param name="state">The row state.</param> public void SetAction(DBRowState state) { if (this.HasAction == true) { this.Xml.Attribute("action").Value = state.ToStateName(); } else { this.Xml.Add(new XAttribute("action", state.ToStateName())); } }
/// <summary> /// Converts <see cref="DBRowState"/> to string value. /// </summary> /// <param name="rowState">The <see cref="DBRowState"/> to convert.</param> /// <returns>The string value of specified<see cref="DBRowState"/>.</returns> public static string ToStateName(this DBRowState rowState) { return(rowState.ToString().ToLowerInvariant()); }