Chill.RestRequest.GetProperties C# (CSharp) Метод

GetProperties() приватный статический Метод

private static GetProperties ( object o ) : IEnumerable
o object
Результат IEnumerable
        private static IEnumerable<PropertyValue> GetProperties(object o)
        {
            if (o != null)
            {
                PropertyDescriptorCollection props = TypeDescriptor.GetProperties(o);
                foreach (PropertyDescriptor prop in props)
                {
                    object val = prop.GetValue(o);
                    if (val != null)
                    {
                        yield return new PropertyValue { Name = prop.Name, Value = val };
                    }
                }
            }
        }