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.
1341
1342
1343
1344
|
# File 'lib/webpay/data_types.rb', line 1341
def initialize(hash = {})
hash = normalize_hash(hash)
@attributes = hash
end
|
Instance Attribute Details
#attributes ⇒ Object
Returns the value of attribute attributes.
1322
1323
1324
|
# File 'lib/webpay/data_types.rb', line 1322
def attributes
@attributes
end
|
Class Method Details
.create(params) ⇒ Object
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
|
# File 'lib/webpay/data_types.rb', line 1329
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
1324
1325
1326
|
# File 'lib/webpay/data_types.rb', line 1324
def self.fields
['id']
end
|
Instance Method Details
#id ⇒ Object
1359
1360
1361
|
# File 'lib/webpay/data_types.rb', line 1359
def id
attributes['id']
end
|
#id=(value) ⇒ Object
1363
1364
1365
|
# File 'lib/webpay/data_types.rb', line 1363
def id=(value)
attributes['id'] = value
end
|
#query_params ⇒ Object
1352
1353
1354
1355
|
# File 'lib/webpay/data_types.rb', line 1352
def query_params
result = {}
return result
end
|
#request_body ⇒ Object
1347
1348
1349
1350
|
# File 'lib/webpay/data_types.rb', line 1347
def request_body
result = {}
result
end
|