Class: Intelligence::MessageContent::Base
- Inherits:
-
Object
- Object
- Intelligence::MessageContent::Base
show all
- Extended by:
- AdaptiveConfiguration::Configurable
- Defined in:
- lib/intelligence/message_content/base.rb
Class Method Summary
collapse
Instance Method Summary
collapse
Constructor Details
#initialize(attributes = {}) ⇒ Base
Returns a new instance of Base.
15
16
17
18
19
|
# File 'lib/intelligence/message_content/base.rb', line 15
def initialize( attributes = {} )
attributes.each do | key, value |
instance_variable_set( "@#{key}", value.freeze ) if self.respond_to?( "#{key}" )
end
end
|
Class Method Details
.build(attributes = nil, &block) ⇒ Object
7
8
9
|
# File 'lib/intelligence/message_content/base.rb', line 7
def self.build( attributes = nil, &block )
self.new( self.configure( attributes, &block ) )
end
|
.build!(attributes = nil, &block) ⇒ Object
11
12
13
|
# File 'lib/intelligence/message_content/base.rb', line 11
def self.build!( attributes = nil, &block )
self.new( self.configure!( attributes, &block ) )
end
|
Instance Method Details
#valid? ⇒ Boolean
21
22
23
|
# File 'lib/intelligence/message_content/base.rb', line 21
def valid?
false
end
|