Class: SPQR::SchemaClass::SchemaMethod
- Inherits:
-
Object
- Object
- SPQR::SchemaClass::SchemaMethod
- Defined in:
- lib/spqr/codegen.rb
Instance Attribute Summary collapse
-
#args ⇒ Object
Returns the value of attribute args.
-
#desc ⇒ Object
Returns the value of attribute desc.
-
#name ⇒ Object
Returns the value of attribute name.
-
#options ⇒ Object
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(nm, desc, opts = nil) ⇒ SchemaMethod
constructor
A new instance of SchemaMethod.
Constructor Details
#initialize(nm, desc, opts = nil) ⇒ SchemaMethod
Returns a new instance of SchemaMethod.
99 100 101 102 103 104 |
# File 'lib/spqr/codegen.rb', line 99 def initialize(nm,desc,opts=nil) @options = (opts && opts.dup) || {} @name = nm @desc = desc.gsub(/\s+/, " ") if desc @args = arg_struct end |
Instance Attribute Details
#args ⇒ Object
Returns the value of attribute args.
98 99 100 |
# File 'lib/spqr/codegen.rb', line 98 def args @args end |
#desc ⇒ Object
Returns the value of attribute desc.
98 99 100 |
# File 'lib/spqr/codegen.rb', line 98 def desc @desc end |
#name ⇒ Object
Returns the value of attribute name.
98 99 100 |
# File 'lib/spqr/codegen.rb', line 98 def name @name end |
#options ⇒ Object
Returns the value of attribute options.
98 99 100 |
# File 'lib/spqr/codegen.rb', line 98 def @options end |