class Swagger::Object
- Swagger::Object
- Reference
- Object
Overview
Object is define a schema struct
This is no relationship with
Objects
structs.
Swagger::Object.new("User", "object", [
Swagger::Property.new("id", "integer", "int32", example: 1),
Swagger::Property.new("nickname", example: "icyleaf wang"),
Swagger::Property.new("username", example: "icyleaf"),
Swagger::Property.new("email", example: "[email protected]"),
Swagger::Property.new("bio", "Personal bio"),
])
Defined in:
swagger/object.crConstructors
Instance Method Summary
- #items : String | Swagger::Object | Nil
- #items=(items : String | Swagger::Object | Nil)
- #name : String
- #name=(name : String)
- #properties : Array(Swagger::Property)?
- #properties=(properties : Nil | Array(Swagger::Property))
- #type : String
- #type=(type : String)
Constructor Detail
def self.new(name : String, type : String, properties : Array(Property) | Nil = nil, items : self | String | Nil = nil)
#