コード例 #1
0
            public object?GetNthMask(int index)
            {
                ColorFrame_FieldIndex enu = (ColorFrame_FieldIndex)index;

                switch (enu)
                {
                case ColorFrame_FieldIndex.Time:
                    return(Time);

                case ColorFrame_FieldIndex.Color:
                    return(Color);

                default:
                    throw new ArgumentException($"Index is out of range: {index}");
                }
            }
コード例 #2
0
            public void SetNthMask(int index, object obj)
            {
                ColorFrame_FieldIndex enu = (ColorFrame_FieldIndex)index;

                switch (enu)
                {
                case ColorFrame_FieldIndex.Time:
                    this.Time = (Exception?)obj;
                    break;

                case ColorFrame_FieldIndex.Color:
                    this.Color = (Exception?)obj;
                    break;

                default:
                    throw new ArgumentException($"Index is out of range: {index}");
                }
            }