Is it possible to create Rails ActiveRecord attribute with some sort of options? Here is what I mean. Let's say we have a model called Article which defines blog article. One of the attributes says that this article is a post with image, or a post with image, or a post with plain text. Each option will trigger different layout to render. Attribute has certain number of predefined options.
How can I add such attribute "post type" to a model?