Class: WebPay::CreatedRange
Instance Attribute Summary collapse
-
#attributes ⇒ Object
readonly
Returns the value of attribute attributes.
Class Method Summary collapse
Instance Method Summary collapse
-
#gt ⇒ Object
attributes accessors.
- #gt=(value) ⇒ Object
- #gte ⇒ Object
- #gte=(value) ⇒ Object
-
#initialize(hash = {}) ⇒ CreatedRange
constructor
A new instance of CreatedRange.
- #lt ⇒ Object
- #lt=(value) ⇒ Object
- #lte ⇒ Object
- #lte=(value) ⇒ Object
- #query_params ⇒ Object
- #request_body ⇒ Object
Methods inherited from Entity
Constructor Details
#initialize(hash = {}) ⇒ CreatedRange
Returns a new instance of CreatedRange.
620 621 622 623 |
# File 'lib/webpay/data_types.rb', line 620 def initialize(hash = {}) hash = normalize_hash(hash) @attributes = hash end |
Instance Attribute Details
#attributes ⇒ Object (readonly)
Returns the value of attribute attributes.
603 604 605 |
# File 'lib/webpay/data_types.rb', line 603 def attributes @attributes end |
Class Method Details
.create(params) ⇒ Object
610 611 612 613 614 615 616 617 618 |
# File 'lib/webpay/data_types.rb', line 610 def self.create(params) return params if params.is_a?(self) hash = case params when Hash; params else raise WebPay::InvalidRequestError.new("#{self} does not accept the given value", params) end self.new(hash) end |
.fields ⇒ Object
605 606 607 |
# File 'lib/webpay/data_types.rb', line 605 def self.fields ['gt', 'gte', 'lt', 'lte'] end |
Instance Method Details
#gt ⇒ Object
attributes accessors
642 643 644 |
# File 'lib/webpay/data_types.rb', line 642 def gt attributes['gt'] end |
#gt=(value) ⇒ Object
646 647 648 |
# File 'lib/webpay/data_types.rb', line 646 def gt=(value) attributes['gt'] = value end |
#gte ⇒ Object
650 651 652 |
# File 'lib/webpay/data_types.rb', line 650 def gte attributes['gte'] end |
#gte=(value) ⇒ Object
654 655 656 |
# File 'lib/webpay/data_types.rb', line 654 def gte=(value) attributes['gte'] = value end |
#lt ⇒ Object
658 659 660 |
# File 'lib/webpay/data_types.rb', line 658 def lt attributes['lt'] end |
#lt=(value) ⇒ Object
662 663 664 |
# File 'lib/webpay/data_types.rb', line 662 def lt=(value) attributes['lt'] = value end |
#lte ⇒ Object
666 667 668 |
# File 'lib/webpay/data_types.rb', line 666 def lte attributes['lte'] end |
#lte=(value) ⇒ Object
670 671 672 |
# File 'lib/webpay/data_types.rb', line 670 def lte=(value) attributes['lte'] = value end |
#query_params ⇒ Object
631 632 633 634 635 636 637 638 |
# File 'lib/webpay/data_types.rb', line 631 def query_params result = {} copy_if_exists(@attributes, result, 'gt', 'query_params'); copy_if_exists(@attributes, result, 'gte', 'query_params'); copy_if_exists(@attributes, result, 'lt', 'query_params'); copy_if_exists(@attributes, result, 'lte', 'query_params'); return result end |
#request_body ⇒ Object
626 627 628 629 |
# File 'lib/webpay/data_types.rb', line 626 def request_body result = {} result end |