Class: HealthVault::WCData::Methods::GetThingType::Info

Inherits:
ComplexType
  • Object
show all
Defined in:
lib/wc_data/generated/methods/get_thing_type/info.rb

Instance Attribute Summary

Attributes inherited from ComplexType

#tag_name

Instance Method Summary collapse

Methods inherited from ComplexType

#add_new_to_children, #element, #method_missing, #optional_elements, #parse_element, #query_elements, #required_elements, #to_s, #valid?

Constructor Details

#initializeInfo

Returns a new instance of Info.



91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 91

def initialize
  super
  self.tag_name = 'info'

  
  @children['id'] = {:name => 'id', :class => HealthVault::WCData::Types::Guid, :value => Array.new, :min => 0, :max => 999999, :order => 1, :place => :element, :choice => 0 }
  

  
  @children['section'] = {:name => 'section', :class => HealthVault::WCData::Methods::GetThingType::ThingTypeSectionSpec, :value => Array.new, :min => 0, :max => 5, :order => 2, :place => :element, :choice => 0 }
  

  
  @children['image-type'] = {:name => 'image-type', :class => String, :value => Array.new, :min => 0, :max => 999999, :order => 3, :place => :element, :choice => 0 }
  

  
  @children['last-client-refresh'] = {:name => 'last-client-refresh', :class => String, :value => nil, :min => 0, :max => 1, :order => 4, :place => :element, :choice => 0 }
    
  

end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class HealthVault::WCData::ComplexType

Instance Method Details

#add_id(value) ⇒ Object

value is a HealthVault::WCData::Types::Guid



19
20
21
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 19

def add_id(value)
  @children['id'][:value] << value
end

#add_image_type(value) ⇒ Object

value is a String



57
58
59
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 57

def add_image_type(value)
  @children['image-type'][:value] << value
end

#add_section(value) ⇒ Object

value is a HealthVault::WCData::Methods::GetThingType::ThingTypeSectionSpec



38
39
40
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 38

def add_section(value)
  @children['section'][:value] << value
end

#idObject

returns: a HealthVault::WCData::Types::Guid Array



31
32
33
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 31

def id
  return @children['id'][:value]
end

#image_typeObject

remarks: This requests an image of the specified mime type should be returned. For example, to request a GIF image, “image/gif” should be specified. For icons, “image/vnd.microsoft.icon” should be specified. Note, not all thing types will have all image types and some may not have any images at all. If ‘*’ is specified, all image types will be returned. returns: a String Array



70
71
72
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 70

def image_type
  return @children['image-type'][:value]
end

#last_client_refreshObject

returns: a String



85
86
87
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 85

def last_client_refresh
  return @children['last-client-refresh'][:value]
end

#last_client_refresh=(value) ⇒ Object

remarks: This parameter is typically used by callers who cache the results of the response. You can timestamp the data returned and then poll for thing type updates periodically and pass that timestamp in this parameter. The server will determine if any updates have occurred since that timestamp and only return results if there were any updates. This determination does not take into account the data you are asking for in the section or image-type specified but for all thing type definitions. Note, there may be slight variations between servers depending on when each server was updated with the new data. This variation may differ in a number of minutes but under normal conditions will be less than an hour. value is a String



80
81
82
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 80

def last_client_refresh=(value)
  @children['last-client-refresh'][:value] = value
end

#remove_id(value) ⇒ Object

value is a #HealthVault::WCData::Types::Guid



24
25
26
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 24

def remove_id(value)
    @children['id'][:value].delete(value)
end

#remove_image_type(value) ⇒ Object

value is a #String



62
63
64
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 62

def remove_image_type(value)
    @children['image-type'][:value].delete(value)
end

#remove_section(value) ⇒ Object

value is a #HealthVault::WCData::Methods::GetThingType::ThingTypeSectionSpec



43
44
45
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 43

def remove_section(value)
    @children['section'][:value].delete(value)
end

#sectionObject

returns: a HealthVault::WCData::Methods::GetThingType::ThingTypeSectionSpec Array



50
51
52
# File 'lib/wc_data/generated/methods/get_thing_type/info.rb', line 50

def section
  return @children['section'][:value]
end