Class: Api::ResponseBuilder::Messages

Inherits:
Base
  • Object
show all
Defined in:
lib/api/response_builder/messages.rb

Overview

Class which helps in building messges for api response

Instance Attribute Summary collapse

Attributes inherited from Base

#config, #resource

Instance Method Summary collapse

Constructor Details

#initialize(resource, config = {}) ⇒ Messages

Returns a new instance of Messages.



8
9
10
11
12
# File 'lib/api/response_builder/messages.rb', line 8

def initialize(resource, config = {})
  super(resource, config)
  @messages = {}
  set_messages
end

Instance Attribute Details

#messagesObject

Returns the value of attribute messages.



6
7
8
# File 'lib/api/response_builder/messages.rb', line 6

def messages
  @messages
end