/// <summary>Gets a struct containing all values of the row.</summary> /// <param name="layout">Table layout.</param> /// <typeparam name="TStruct">Structure type.</typeparam> /// <returns>A new structure instance.</returns> public TStruct GetStruct <TStruct>(RowLayout layout) where TStruct : struct { if (!layout.IsTyped) { throw new NotSupportedException("This Row was not created from a typed layout!"); } object result = default(TStruct); layout.SetValues(ref result, Values); return((TStruct)result); }