Class: Qt::DBusReply
Instance Method Summary collapse
- #error ⇒ Object
-
#initialize(reply) ⇒ DBusReply
constructor
A new instance of DBusReply.
- #isValid ⇒ Object
- #valid? ⇒ Boolean
- #value ⇒ Object
Constructor Details
#initialize(reply) ⇒ DBusReply
Returns a new instance of DBusReply.
513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 |
# File 'lib/qt/qtruby4.rb', line 513 def initialize(reply) @error = Qt::DBusError.new(reply) if @error.valid? @data = Qt::Variant.new return end if reply.arguments.length >= 1 @data = reply.arguments[0] return end # error @error = Qt::DBusError.new( Qt::DBusError::InvalidSignature, "Unexpected reply signature" ) @data = Qt::Variant.new # clear it end |
Instance Method Details
#error ⇒ Object
544 545 546 |
# File 'lib/qt/qtruby4.rb', line 544 def error return @error end |
#isValid ⇒ Object
532 533 534 |
# File 'lib/qt/qtruby4.rb', line 532 def isValid return !@error.isValid end |
#valid? ⇒ Boolean
536 537 538 |
# File 'lib/qt/qtruby4.rb', line 536 def valid? return !@error.isValid end |
#value ⇒ Object
540 541 542 |
# File 'lib/qt/qtruby4.rb', line 540 def value return @data.value end |