zoukankan      html  css  js  c++  java
  • C# 自定义集合

    using System;
    using System.Collections;
    
    namespace Lucia
    {
        [Serializable]
        public sealed class ClassCollection : CollectionBase
        {
            public int Add(Class value)
            {
                return base.List.Add(value);
            }
    
            public void AddRange(Class[] values)
            {
                foreach (Class info in values)
                {
                    this.Add(info);
                }
            }
    
            public void AddRange(IEnumerable @enum)
            {
                foreach (Class info in @enum)
                {
                    this.Add(info);
                }
            }
    
            public bool Contains(Class value)
            {
                return base.List.Contains(value);
            }
    
            public int IndexOf(Class value)
            {
                return base.List.IndexOf(value);
            }
    
            public void Insert(int index, Class value)
            {
                base.List.Insert(index, value);
            }
    
            public void Remove(Class value)
            {
                base.List.Remove(value);
            }
    
            public void CopyTo(Class[] array, int index)
            {
                ICollection is2 = this;
                is2.CopyTo(array, index);
            }
    
            public Class[] ToArray()
            {
                Class[] array = new Class[base.Count];
                this.CopyTo(array, 0);
                return array;
            }
    
            public Class this[int index]
            {
                get
                {
                    return (Class)base.List[index];
                }
                set
                {
                    base.List[index] = value;
                }
            }
        }
    
        public class Class
        {
        }
    }
  • 相关阅读:
    vue-常用指令汇总
    vue-插槽和具名插槽
    vue-传值校验
    vue-动态组件
    vue-组件
    zend studio 快捷键收集
    php调试工具firephp
    zend studio插件
    MySQL各个版本区别
    PHP 中 Date 函数与实际时间相差8小时的解决方法
  • 原文地址:https://www.cnblogs.com/luciakally/p/4852811.html
Copyright © 2011-2022 走看看