public TValue[] TryGetParamsAttributeValue <TValue>(int index, TValue[] defaultValue = null) { if (AttributeValues.Length <= index) { return(defaultValue); } return(AttributeValues[index].GetValue <object>() as TValue[] ?? AttributeValues.Skip(index).OfType <TValue>().ToArray()); }