Esempio n. 1
0
        public long?AddBuilding(ViewAddress v, Guid userId)
        {
            Trace.Assert(_db != null);
            Trace.Assert(v != null);
            ObjectResult <long?> result = _db.AddBuilding(v.Building, v.StreetID, userId);

            Trace.Assert(result != null);
            IEnumerator <long?> resultList = result.GetEnumerator();

            Trace.Assert(resultList != null);
            resultList.MoveNext();
            long?id = resultList.Current;

            resultList.Dispose(); //  for transaction to be able to complete
            return(id);
        }