Class: Svix::EventTypeImportOpenApiOut
- Inherits:
-
Object
- Object
- Svix::EventTypeImportOpenApiOut
- Defined in:
- lib/svix/models/event_type_import_open_api_out.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
Returns the value of attribute data.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ EventTypeImportOpenApiOut
constructor
A new instance of EventTypeImportOpenApiOut.
- #serialize ⇒ Object
-
#to_json ⇒ Object
Serializes the object to a json string.
Constructor Details
#initialize(attributes = {}) ⇒ EventTypeImportOpenApiOut
Returns a new instance of EventTypeImportOpenApiOut.
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/svix/models/event_type_import_open_api_out.rb', line 12 def initialize(attributes = {}) unless attributes.is_a?(Hash) fail( ArgumentError, "The input argument (attributes) must be a hash in `Svix::EventTypeImportOpenApiOut` new method" ) end attributes.each do |k, v| unless ALL_FIELD.include?(k.to_s) fail(ArgumentError, "The field #{k} is not part of Svix::EventTypeImportOpenApiOut") end instance_variable_set("@#{k}", v) instance_variable_set("@__#{k}_is_defined", true) end end |
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data.
7 8 9 |
# File 'lib/svix/models/event_type_import_open_api_out.rb', line 7 def data @data end |
Class Method Details
.deserialize(attributes = {}) ⇒ Object
30 31 32 33 34 35 |
# File 'lib/svix/models/event_type_import_open_api_out.rb', line 30 def self.deserialize(attributes = {}) attributes = attributes.transform_keys(&:to_s) attrs = Hash.new attrs["data"] = Svix::EventTypeImportOpenApiOutData.deserialize(attributes["data"]) new(attrs) end |
Instance Method Details
#serialize ⇒ Object
37 38 39 40 41 |
# File 'lib/svix/models/event_type_import_open_api_out.rb', line 37 def serialize out = Hash.new out["data"] = Svix::serialize_schema_ref(@data) if @data out end |
#to_json ⇒ Object
Serializes the object to a json string
45 46 47 |
# File 'lib/svix/models/event_type_import_open_api_out.rb', line 45 def to_json JSON.dump(serialize) end |