Babel.Compiler.TypeManager.AddCustomAttribute C# (CSharp) Метод

AddCustomAttribute() публичный Метод

public AddCustomAttribute ( ICustomAttributeProvider provider, Attribute attribute ) : void
provider ICustomAttributeProvider
attribute System.Attribute
Результат void
        public virtual void AddCustomAttribute(ICustomAttributeProvider provider,
                               Attribute attribute)
        {
            object[] attrs = (object[]) customAttributesTable[provider];
            if (attrs == null) {
                customAttributesTable[provider] = new object[] { attribute };
            }
            else {
                object[] newAttrs = new object[attrs.Length + 1];
                Array.Copy(attrs, newAttrs, attrs.Length);
                newAttrs[attrs.Length] = attribute;
                customAttributesTable[provider] = newAttrs;
            }
        }