Class: SFML::Network::Ftp::ListingResponse
- Inherits:
-
Object
- Object
- SFML::Network::Ftp::ListingResponse
- Defined in:
- lib/sfml/network/ftp.rb
Overview
Returned by directory_listing — adds the #names array.
Instance Attribute Summary collapse
-
#handle ⇒ Object
readonly
:nodoc:.
Instance Method Summary collapse
-
#count ⇒ Object
Returns the count.
-
#message ⇒ Object
Returns the message.
-
#names ⇒ Object
Filenames returned by the listing, as an Array of Strings.
-
#ok? ⇒ Boolean
trueif ok. -
#status ⇒ Object
Returns the status.
-
#status_symbol ⇒ Object
Returns the status symbol.
Instance Attribute Details
#handle ⇒ Object (readonly)
:nodoc:
203 204 205 |
# File 'lib/sfml/network/ftp.rb', line 203 def handle @handle end |
Instance Method Details
#count ⇒ Object
Returns the count.
202 |
# File 'lib/sfml/network/ftp.rb', line 202 def count = C::Network.sfFtpListingResponse_getCount(@handle) |
#message ⇒ Object
Returns the message.
200 201 |
# File 'lib/sfml/network/ftp.rb', line 200 def = C::Network.sfFtpListingResponse_getMessage(@handle).to_s # Returns the count. |
#names ⇒ Object
Filenames returned by the listing, as an Array of Strings.
206 207 208 |
# File 'lib/sfml/network/ftp.rb', line 206 def names Array.new(count) { |i| C::Network.sfFtpListingResponse_getName(@handle, i).to_s } end |
#ok? ⇒ Boolean
true if ok.
194 195 |
# File 'lib/sfml/network/ftp.rb', line 194 def ok? = C::Network.sfFtpListingResponse_isOk(@handle) # Returns the status. |
#status ⇒ Object
Returns the status.
196 197 |
# File 'lib/sfml/network/ftp.rb', line 196 def status = C::Network.sfFtpListingResponse_getStatus(@handle) # Returns the status symbol. |
#status_symbol ⇒ Object
Returns the status symbol.
198 199 |
# File 'lib/sfml/network/ftp.rb', line 198 def status_symbol = STATUS_NAMES[status] || status # Returns the message. |