Class: MobyBehaviour::QT::ApiMethod::MethodReturnValue

Inherits:
Object
  • Object
show all
Defined in:
lib/testability-driver-plugins/testability-driver-qt-sut-plugin/behaviours/qt_api_method.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(type, value) ⇒ MethodReturnValue

Returns a new instance of MethodReturnValue.

Raises:

  • (ArgumentError)


30
31
32
33
34
# File 'lib/testability-driver-plugins/testability-driver-qt-sut-plugin/behaviours/qt_api_method.rb', line 30

def initialize( type, value )
	raise ArgumentError.new("Invalid argument type for type. (Actual: %s, Expected: String)" % [ type.class.to_s ] ) unless type.kind_of?( String )
	raise ArgumentError.new("Invalid argument type for value. (Actual: %s, Expected: String)" % [ value.class.to_s ] ) unless value.kind_of?( String )
	@type, @value = type, value
end

Instance Attribute Details

#typeObject (readonly)

Returns the value of attribute type.



28
29
30
# File 'lib/testability-driver-plugins/testability-driver-qt-sut-plugin/behaviours/qt_api_method.rb', line 28

def type
  @type
end

#valueObject (readonly)

Returns the value of attribute value.



28
29
30
# File 'lib/testability-driver-plugins/testability-driver-qt-sut-plugin/behaviours/qt_api_method.rb', line 28

def value
  @value
end

Instance Method Details

#==(value) ⇒ Object



40
41
42
# File 'lib/testability-driver-plugins/testability-driver-qt-sut-plugin/behaviours/qt_api_method.rb', line 40

def ==( value )
	value == @value
end

#to_sObject



36
37
38
# File 'lib/testability-driver-plugins/testability-driver-qt-sut-plugin/behaviours/qt_api_method.rb', line 36

def to_s
	@value
end