Class: SDM::PolicyGetResponse
- Inherits:
-
Object
- Object
- SDM::PolicyGetResponse
- Defined in:
- lib/models/porcelain.rb
Overview
PolicyGetResponse returns a requested Policy.
Instance Attribute Summary collapse
-
#meta ⇒ Object
Reserved for future use.
-
#policy ⇒ Object
The requested Policy.
-
#rate_limit ⇒ Object
Rate limit information.
Instance Method Summary collapse
-
#initialize(meta: nil, policy: nil, rate_limit: nil) ⇒ PolicyGetResponse
constructor
A new instance of PolicyGetResponse.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(meta: nil, policy: nil, rate_limit: nil) ⇒ PolicyGetResponse
Returns a new instance of PolicyGetResponse.
12784 12785 12786 12787 12788 12789 12790 12791 12792 |
# File 'lib/models/porcelain.rb', line 12784 def initialize( meta: nil, policy: nil, rate_limit: nil ) = == nil ? nil : @policy = policy == nil ? nil : policy @rate_limit = rate_limit == nil ? nil : rate_limit end |
Instance Attribute Details
#meta ⇒ Object
Reserved for future use.
12778 12779 12780 |
# File 'lib/models/porcelain.rb', line 12778 def end |
#policy ⇒ Object
The requested Policy.
12780 12781 12782 |
# File 'lib/models/porcelain.rb', line 12780 def policy @policy end |
#rate_limit ⇒ Object
Rate limit information.
12782 12783 12784 |
# File 'lib/models/porcelain.rb', line 12782 def rate_limit @rate_limit end |
Instance Method Details
#to_json(options = {}) ⇒ Object
12794 12795 12796 12797 12798 12799 12800 |
# File 'lib/models/porcelain.rb', line 12794 def to_json( = {}) hash = {} self.instance_variables.each do |var| hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var end hash.to_json end |