Class: MasterCard::API::P2m::MerchantTransfer

Inherits:
Core::Model::BaseObject
  • Object
show all
Includes:
Core::Model
Defined in:
lib/mastercard/api/p2m/merchanttransfer.rb

Class Method Summary collapse

Class Method Details

.readByID(id, criteria = nil) ⇒ Object



65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/mastercard/api/p2m/merchanttransfer.rb', line 65

def self.readByID(id, criteria = nil)
	#
	#Returns objects of type MerchantTransfer by id and optional criteria
	#@param [String] id
	#@param [Dict] criteria
	#@return [MerchantTransfer] object representing the response
	#@raise [APIException] an exception from the response status

	mapObj = MerchantTransfer.new
	if !(id.nil? || id.to_s.empty?)
	  mapObj.set("id", id)
	end
	if !criteria.nil?
		if criteria.instance_of? RequestMap
		  mapObj.setAll(criteria.getObject())
		else
		  mapObj.setAll(criteria)
		end
	end

	return self.execute("3e96fa85-fb5e-46da-b145-13364df01fb3",MerchantTransfer.new(mapObj))
end

.readByReference(criteria) ⇒ Object



95
96
97
98
99
100
101
102
103
104
# File 'lib/mastercard/api/p2m/merchanttransfer.rb', line 95

def self.readByReference(criteria)
	#
	#Query objects of type MerchantTransfer by id and optional criteria
	#@param [Dict] criteria
	#@return [MerchantTransfer] object representing the response.
	#@raise [APIException] an exception from the response status
	#

	return self.execute("96f05a15-22f3-43d1-9bc3-b0f8768c94f0",MerchantTransfer.new(criteria))
end