2018-04-17 12:18:40 +00:00
|
|
|
class Components(object):
|
|
|
|
"""Represents an OpenAPI Components in a service."""
|
|
|
|
|
|
|
|
def __init__(
|
|
|
|
self, schemas=None, responses=None, parameters=None,
|
2020-02-04 01:21:46 +00:00
|
|
|
request_bodies=None, security_schemes=None):
|
2018-04-17 12:18:40 +00:00
|
|
|
self.schemas = schemas and dict(schemas) or {}
|
|
|
|
self.responses = responses and dict(responses) or {}
|
|
|
|
self.parameters = parameters and dict(parameters) or {}
|
|
|
|
self.request_bodies = request_bodies and dict(request_bodies) or {}
|
2020-02-04 01:21:46 +00:00
|
|
|
self.security_schemes = (
|
|
|
|
security_schemes and dict(security_schemes) or {}
|
|
|
|
)
|