[code language=”csharp”]
public class Person {
private const int DEFAULT_AGE = 18;
private int _age = DEFAULT_AGE;
[DefaultValue(DEFAULT_AGE)]
public int Age {
get { return _age; }
set { _age = value; }
}
}
[/code]
http://stackoverflow.com/questions/6779881/annotating-properties-on-a-model-with-default-values