public HalBuilder AddPublicPropertiesOf <T>(T resource) { foreach (var propertyInfo in resource.GetType().GetProperties()) { if (propertyInfo.GetGetMethod() != null) { RepresentationAsDictionary.Add(propertyInfo.Name, propertyInfo.GetGetMethod().Invoke(resource, null)); } } return(this); }
public HalBuilder AddProperty(string name, object value) { RepresentationAsDictionary.Add(name, value); return(this); }