Class: SFML::Network::Ftp::ListingResponse

Inherits:
Object
  • Object
show all
Defined in:
lib/sfml/network/ftp.rb

Overview

Returned by directory_listing — adds the ‘#names` array.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#handleObject (readonly)

:nodoc:



168
169
170
# File 'lib/sfml/network/ftp.rb', line 168

def handle
  @handle
end

Instance Method Details

#countObject



167
# File 'lib/sfml/network/ftp.rb', line 167

def count         = C::Network.sfFtpListingResponse_getCount(@handle)

#messageObject



166
# File 'lib/sfml/network/ftp.rb', line 166

def message       = C::Network.sfFtpListingResponse_getMessage(@handle).to_s

#namesObject



170
171
172
# File 'lib/sfml/network/ftp.rb', line 170

def names
  Array.new(count) { |i| C::Network.sfFtpListingResponse_getName(@handle, i).to_s }
end

#ok?Boolean

Returns:

  • (Boolean)


163
# File 'lib/sfml/network/ftp.rb', line 163

def ok?           = C::Network.sfFtpListingResponse_isOk(@handle)

#statusObject



164
# File 'lib/sfml/network/ftp.rb', line 164

def status        = C::Network.sfFtpListingResponse_getStatus(@handle)

#status_symbolObject



165
# File 'lib/sfml/network/ftp.rb', line 165

def status_symbol = STATUS_NAMES[status] || status