Class: Swagger::Schema::Content
- Inherits:
-
Object
- Object
- Swagger::Schema::Content
- Defined in:
- lib/swagger/schema/content.rb
Class Method Summary collapse
Instance Method Summary collapse
- #[](type) ⇒ Object
-
#initialize(schema) ⇒ Content
constructor
A new instance of Content.
Constructor Details
#initialize(schema) ⇒ Content
Returns a new instance of Content.
7 8 9 |
# File 'lib/swagger/schema/content.rb', line 7 def initialize(schema) @schema = schema end |
Class Method Details
.shortcut(name, type) ⇒ Object
16 17 18 |
# File 'lib/swagger/schema/content.rb', line 16 def self.shortcut(name, type) define_method(name) { self[type] } end |