Class: Io::Flow::V0::Models::FtpServer
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::FtpServer
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#hostname ⇒ Object
readonly
Returns the value of attribute hostname.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ FtpServer
constructor
A new instance of FtpServer.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ FtpServer
Returns a new instance of FtpServer.
38782 38783 38784 38785 38786 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 38782 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:hostname], 'FtpServer') @hostname = HttpClient::Preconditions.assert_class('hostname', opts.delete(:hostname), String) end |
Instance Attribute Details
#hostname ⇒ Object (readonly)
Returns the value of attribute hostname.
38780 38781 38782 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 38780 def hostname @hostname end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
38792 38793 38794 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 38792 def copy(incoming={}) FtpServer.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
38796 38797 38798 38799 38800 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 38796 def to_hash { :hostname => hostname } end |
#to_json ⇒ Object
38788 38789 38790 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 38788 def to_json JSON.dump(to_hash) end |