ICoreRow.cs 768 B

1234567891011121314151617181920212223
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq.Expressions;
  4. namespace InABox.Core
  5. {
  6. public interface ICoreRow
  7. {
  8. object? this[string columnName] { get; set; }
  9. int Index { get; }
  10. CoreTable Table { get; }
  11. List<object?> Values { get; }
  12. T Get<T>(string columnname, bool usedefault = true);
  13. TType Get<TSource, TType>(Expression<Func<TSource, TType>> expression, bool usedefault = true);
  14. void Set<T>(string columnname, T value);
  15. void Set<TSource, TType>(Expression<Func<TSource, TType>> expression, TType value);
  16. Dictionary<string, object?> ToDictionary(string[] exclude);
  17. BaseObject ToObject(Type t);
  18. T ToObject<T>() where T : BaseObject, new();
  19. }
  20. }