This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// All conventions implement this interface. The "Apply" method is responsible for determining if a convention | |
// applies, as well as the actual transformation of the metadata. (I'm working on an enhanced version that | |
// separates the "is a match" logic from the actual metadata application.) | |
public interface IMetadataConvention | |
{ | |
void Apply(IEnumerable<Attribute> attributes, ModelMetadata metadata); | |
} | |
// This convention applies our default naming convention. This convention will split a "pascal-cased" property name | |
// into individual words. For example, "BorrowerFirstName" would become "Borrower First Name". This convention can |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class TrimmedString : IUserType | |
{ | |
public bool IsMutable | |
{ | |
get { return false; } | |
} | |
public Type ReturnedType | |
{ | |
get { return typeof (string); } | |
} |