Object.cs 341 B

123456789101112131415161718192021222324252627
  1. using System.ComponentModel;
  2. namespace Model
  3. {
  4. public abstract class Object: ISupportInitialize
  5. {
  6. public long Id { get; set; }
  7. protected Object()
  8. {
  9. Id = IdGenerater.GenerateId();
  10. }
  11. protected Object(long id)
  12. {
  13. this.Id = id;
  14. }
  15. public virtual void BeginInit()
  16. {
  17. }
  18. public virtual void EndInit()
  19. {
  20. }
  21. }
  22. }