Class: Grape::Builder::Partial
- Inherits:
-
Object
- Object
- Grape::Builder::Partial
- Defined in:
- lib/grape/builder/partial.rb
Instance Attribute Summary collapse
-
#scope ⇒ Object
readonly
Returns the value of attribute scope.
-
#view_path ⇒ Object
readonly
Returns the value of attribute view_path.
Instance Method Summary collapse
-
#initialize(view_path, scope) ⇒ Partial
constructor
A new instance of Partial.
- #render(template, locals = {}) ⇒ Object
Constructor Details
#initialize(view_path, scope) ⇒ Partial
Returns a new instance of Partial.
9 10 11 12 |
# File 'lib/grape/builder/partial.rb', line 9 def initialize(view_path, scope) @view_path = view_path @scope = scope end |
Instance Attribute Details
#scope ⇒ Object (readonly)
Returns the value of attribute scope.
7 8 9 |
# File 'lib/grape/builder/partial.rb', line 7 def scope @scope end |
#view_path ⇒ Object (readonly)
Returns the value of attribute view_path.
7 8 9 |
# File 'lib/grape/builder/partial.rb', line 7 def view_path @view_path end |