Class: JIRA::CustomFieldValue

Inherits:
DynamicEntity show all
Defined in:
lib/jiraSOAP/entities/custom_field_value.rb

Overview

TODO:

see if @key is always nil from the server, maybe we can remove it

Represents an instance of a custom field (with values). This object is used as a member of Issue objects.

The structure of this class resembles JIRA::FieldValue, it is different in that @values will always be stored as an Array of String objects for custom fields and a field value is more flexible. You can expect the classes to merge in the near future.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Entity

add_attributes, #initialize_with_xml, new_with_xml, #to_soap

Instance Attribute Details

#idString

Corresponds to customfieldId in the javadoc.

Returns:

  • (String)

#keyString

Corresponds to key in the javadoc.

Returns:

  • (String)

#valuesArray<String>

Corresponds to values in the javadoc.

Returns:

  • (Array<String>)

Instance Method Details

#soapify_for(msg, label = 'customFieldValues') ⇒ Handsoap::XmlMason::Element

Generate a SOAP message fragment for the object.

Parameters:

  • msg (Handsoap::XmlMason::Node)

    SOAP message to add the object to

  • label (String) (defaults to: 'customFieldValues')

    tag name used in wrapping tags

Returns:

  • (Handsoap::XmlMason::Element)


20
21
22
23
24
25
26
# File 'lib/jiraSOAP/entities/custom_field_value.rb', line 20

def soapify_for(msg, label = 'customFieldValues')
  msg.add label do |submsg|
    submsg.add 'customfieldId', @id
    submsg.add 'key', @key
    submsg.add_simple_array 'values', @values
  end
end