| 12345678910111213141516171819202122232425262728293031323334 |
- using System;
- using MongoDB.Bson.Serialization.Attributes;
- namespace ETHotfix
- {
- [BsonIgnoreExtraElements]
- public abstract class ComponentWithId : Component
- {
- [BsonIgnoreIfDefault]
- [BsonDefaultValue(0L)]
- [BsonElement]
- [BsonId]
- public long Id { get; set; }
- protected ComponentWithId()
- {
- }
- protected ComponentWithId(long id)
- {
- this.Id = id;
- }
- public override void Dispose()
- {
- if (this.IsDisposed)
- {
- return;
- }
- base.Dispose();
- }
- }
- }
|