Пример #1
0
        internal MutableModelList <T> GetList <T>(MutableObjectBase obj, ModelProperty property)
        {
            Debug.Assert(property.IsCollection);
            var slot = obj.MId.Descriptor.GetSlot(property);

            return(MutableModelList <T> .FromGreenList(obj, slot));
        }
Пример #2
0
        protected MutableModelList <T> GetList <T>(ModelProperty property, ref MutableModelList <T> value)
        {
            MutableModelList <T> result = value;

            if (result == null)
            {
                result = this.model.GetList <T>(this, property);
                result = Interlocked.CompareExchange(ref value, result, null) ?? result;
            }
            return(result);
        }