Class: TestdroidAPI::FilterItem

Inherits:
Object
  • Object
show all
Defined in:
lib/testdroid-api-filter-builder.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, value, operand, type) ⇒ FilterItem

Returns a new instance of FilterItem.



133
134
135
# File 'lib/testdroid-api-filter-builder.rb', line 133

def initialize(name, value, operand, type)
  @name, @value, @operand, @type = name, value, operand, type
end

Instance Attribute Details

#nameObject

Returns the value of attribute name.



131
132
133
# File 'lib/testdroid-api-filter-builder.rb', line 131

def name
  @name
end

#operandObject

Returns the value of attribute operand.



131
132
133
# File 'lib/testdroid-api-filter-builder.rb', line 131

def operand
  @operand
end

#typeObject

Returns the value of attribute type.



131
132
133
# File 'lib/testdroid-api-filter-builder.rb', line 131

def type
  @type
end

#valueObject

Returns the value of attribute value.



131
132
133
# File 'lib/testdroid-api-filter-builder.rb', line 131

def value
  @value
end

Instance Method Details

#to_sObject



141
142
143
# File 'lib/testdroid-api-filter-builder.rb', line 141

def to_s
  "#{@type}_#{@name}_#{@operand}"
end

#valuesObject



137
138
139
# File 'lib/testdroid-api-filter-builder.rb', line 137

def values
  @value.join('|')
end