private void BindComponentParameters()
{
IConverter converter = new DefaultConverter();
PropertyInfo[] properties = GetType().GetProperties(BindingFlags.Public | BindingFlags.Instance);
foreach(PropertyInfo property in properties)
{
if (!property.CanWrite) continue;
object[] attributes = property.GetCustomAttributes(typeof(ViewComponentParamAttribute), true);
if (attributes.Length == 1)
{
BindParameter((ViewComponentParamAttribute) attributes[0], property, converter);
}
}
}