Method: ActiveResource::Base.known_attributes
- Defined in:
- lib/active_resource/base.rb
.known_attributes ⇒ Object
Returns the list of known attributes for this resource, gathered from the provided schema Attributes that are known will cause your resource to return ‘true’ when respond_to? is called on them. A known attribute will return nil if not set (rather than MethodNotFound); thus known attributes can be used with validates_presence_of without a getter-method.
431 432 433 |
# File 'lib/active_resource/base.rb', line 431 def known_attributes @known_attributes ||= [] end |