Class: WebPay::EventIdRequest
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Entity
#normalize_hash, #to_h, #to_s
Constructor Details
Returns a new instance of EventIdRequest.
1406
1407
1408
1409
|
# File 'lib/webpay/data_types.rb', line 1406
def initialize(hash = {})
hash = normalize_hash(hash)
@attributes = hash
end
|
Instance Attribute Details
#attributes ⇒ Object
Returns the value of attribute attributes.
1387
1388
1389
|
# File 'lib/webpay/data_types.rb', line 1387
def attributes
@attributes
end
|
Class Method Details
.create(params) ⇒ Object
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
|
# File 'lib/webpay/data_types.rb', line 1394
def self.create(params)
return params if params.is_a?(self)
hash = case params
when Hash; params
when WebPay::EventResponse; {'id' => params.id}
when String; {'id' => params}
else
raise WebPay::InvalidRequestError.new("#{self} does not accept the given value", params)
end
self.new(hash)
end
|
.fields ⇒ Object
1389
1390
1391
|
# File 'lib/webpay/data_types.rb', line 1389
def self.fields
['id']
end
|
Instance Method Details
#id ⇒ Object
1424
1425
1426
|
# File 'lib/webpay/data_types.rb', line 1424
def id
attributes['id']
end
|
#id=(value) ⇒ Object
1428
1429
1430
|
# File 'lib/webpay/data_types.rb', line 1428
def id=(value)
attributes['id'] = value
end
|
#query_params ⇒ Object
1417
1418
1419
1420
|
# File 'lib/webpay/data_types.rb', line 1417
def query_params
result = {}
return result
end
|
#request_body ⇒ Object
1412
1413
1414
1415
|
# File 'lib/webpay/data_types.rb', line 1412
def request_body
result = {}
result
end
|