Class: ApolloDeploySignalSdkRails::EmailPageResponse
- Inherits:
-
Object
- Object
- ApolloDeploySignalSdkRails::EmailPageResponse
- Defined in:
- lib/apollo_deploy_signal_sdk_rails/types.rb
Overview
Schema type: EmailPageResponse
Instance Attribute Summary collapse
Class Method Summary collapse
-
.from_json(attributes) ⇒ EmailPageResponse
Create an instance from a parsed JSON hash.
Instance Method Summary collapse
-
#initialize(data:, page:) ⇒ EmailPageResponse
constructor
A new instance of EmailPageResponse.
-
#to_h ⇒ Hash
A hash representation of this object.
Constructor Details
#initialize(data:, page:) ⇒ EmailPageResponse
Returns a new instance of EmailPageResponse.
4192 4193 4194 4195 |
# File 'lib/apollo_deploy_signal_sdk_rails/types.rb', line 4192 def initialize(data: , page: ) @data = data @page = page end |
Instance Attribute Details
#data ⇒ Array<EmailDetailResponse>
4187 4188 4189 |
# File 'lib/apollo_deploy_signal_sdk_rails/types.rb', line 4187 def data @data end |
#page ⇒ PageInfo
4189 4190 4191 |
# File 'lib/apollo_deploy_signal_sdk_rails/types.rb', line 4189 def page @page end |
Class Method Details
.from_json(attributes) ⇒ EmailPageResponse
Create an instance from a parsed JSON hash.
4208 4209 4210 4211 4212 4213 4214 4215 |
# File 'lib/apollo_deploy_signal_sdk_rails/types.rb', line 4208 def self.from_json(attributes) return nil unless attributes.is_a?(Hash) new( data: attributes.key?("data") ? attributes["data"] : attributes[:data], page: attributes.key?("page") ? attributes["page"] : attributes[:page], ) end |
Instance Method Details
#to_h ⇒ Hash
Returns a hash representation of this object.
4198 4199 4200 4201 4202 4203 |
# File 'lib/apollo_deploy_signal_sdk_rails/types.rb', line 4198 def to_h { data: @data, page: @page, }.compact end |