2020-10-23 01:48:18 +11:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using Explorer.UI;
|
2020-10-08 06:15:42 +11:00
|
|
|
|
|
2020-10-23 01:48:18 +11:00
|
|
|
|
namespace Explorer.CacheObject
|
|
|
|
|
{
|
|
|
|
|
public class CacheEnumerated : CacheObjectBase
|
|
|
|
|
{
|
|
|
|
|
public int Index { get; set; }
|
|
|
|
|
public IList RefIList { get; set; }
|
|
|
|
|
public InteractiveEnumerable ParentEnumeration { get; set; }
|
2020-10-08 06:15:42 +11:00
|
|
|
|
|
2020-10-23 01:48:18 +11:00
|
|
|
|
public override bool CanWrite => RefIList != null && ParentEnumeration.OwnerCacheObject.CanWrite;
|
2020-10-08 06:15:42 +11:00
|
|
|
|
|
2020-10-23 01:48:18 +11:00
|
|
|
|
public override void SetValue()
|
|
|
|
|
{
|
|
|
|
|
RefIList[Index] = IValue.Value;
|
|
|
|
|
ParentEnumeration.Value = RefIList;
|
2020-10-08 06:15:42 +11:00
|
|
|
|
|
2020-10-23 01:48:18 +11:00
|
|
|
|
ParentEnumeration.OwnerCacheObject.SetValue();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|