Class: DeltaCloud::Documentation::OperationParameter
- Inherits:
-
Object
- Object
- DeltaCloud::Documentation::OperationParameter
- Defined in:
- lib/documentation.rb
Instance Attribute Summary collapse
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#required ⇒ Object
readonly
Returns the value of attribute required.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(data) ⇒ OperationParameter
constructor
A new instance of OperationParameter.
- #to_comment ⇒ Object
Constructor Details
#initialize(data) ⇒ OperationParameter
Returns a new instance of OperationParameter.
44 45 46 |
# File 'lib/documentation.rb', line 44 def initialize(data) @name, @type, @required, @description = data[:name], data[:type], data[:required], data[:description] end |
Instance Attribute Details
#description ⇒ Object (readonly)
Returns the value of attribute description.
42 43 44 |
# File 'lib/documentation.rb', line 42 def description @description end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
39 40 41 |
# File 'lib/documentation.rb', line 39 def name @name end |
#required ⇒ Object (readonly)
Returns the value of attribute required.
41 42 43 |
# File 'lib/documentation.rb', line 41 def required @required end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
40 41 42 |
# File 'lib/documentation.rb', line 40 def type @type end |
Instance Method Details
#to_comment ⇒ Object
48 49 50 |
# File 'lib/documentation.rb', line 48 def to_comment " # @param [#{@type}, #{@name}] #{@description}" end |