예제 #1
0
        protected EntityBase(IDistinctableEntity distinctableEntity)
        {
            if (distinctableEntity == null)
            {
                Id = NullId;
                return;
            }

            Id = distinctableEntity.Id;
        }
예제 #2
0
파일: EntityBase.cs 프로젝트: sGeeK44/Orm
        protected EntityBase(IDistinctableEntity distinctableEntity)
        {
            if (distinctableEntity == null)
            {
                Id = NullId;
                return;
            }

            Id = (long)distinctableEntity.GetPkValue();
        }
예제 #3
0
 private static void CheckIsConsistant(IDistinctableEntity book, ReferenceHolder <Book, long?> manadatory)
 {
     Assert.AreEqual(book, manadatory.Object);
     Assert.AreEqual(book.GetPkValue(), manadatory.Id);
 }
 private static void CheckIsConsistant(IDistinctableEntity book, NullableReferenceHolder <Book> manadatory)
 {
     Assert.AreEqual(book, manadatory.Object);
     Assert.AreEqual(book.Id, manadatory.Id);
 }