Sha256: 9f540e1415cd53c333a6b20befa1cb173ce163b75e34389c8c4849b1f2fc7703

Contents?: true

Size: 577 Bytes

Versions: 1

Compression:

Stored size: 577 Bytes

Contents

#
# custom_field.rb
# ConstantContact
#
# Copyright (c) 2013 Constant Contact. All rights reserved.

module ConstantContact
	module Components
		class CustomField < Component
			attr_accessor :name, :value

			# Factory method to create a CustomField object from a json string
			# @param [Hash] props - array of properties to create object from
			# @return [CustomField]
			def self.create(props)
				custom_field = CustomField.new
				if props
					props.each do |key, value|
						custom_field.send("#{key}=", value)
					end
				end
				custom_field
			end

		end
	end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
constantcontact-1.0.0 lib/constantcontact/components/contacts/custom_field.rb