Class: DocuSign::AnchorTab

Inherits:
DocuSignModel show all
Defined in:
lib/docu_sign/anchor_tab.rb

Constant Summary collapse

ATTRIBUTES =
[:anchor_tab_string, :x_offset, :y_offset, :unit, :ignore_if_not_present]

Instance Method Summary collapse

Methods inherited from DocuSignModel

#method_missing

Constructor Details

#initialize(attributes = {}) ⇒ AnchorTab

Returns a new instance of AnchorTab.



11
12
13
14
15
16
17
# File 'lib/docu_sign/anchor_tab.rb', line 11

def initialize(attributes = {})
  @anchor_tab_string = attributes[:string] || attributes[:anchor_tab_string]
  @x_offset = attributes[:x] || attributes[:x_offset]
  @y_offset = attributes[:y] || attributes[:y_offset]
  @unit = attributes[:unit]
  @ignore_if_not_present = attributes[:ignore_if_not_present]
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class DocuSign::DocuSignModel

Instance Method Details

#to_savonObject



19
20
21
22
23
24
25
26
27
# File 'lib/docu_sign/anchor_tab.rb', line 19

def to_savon
  {
    "AnchorTabString" => self.anchor_tab_string,
    "XOffset" => self.x_offset,
    "YOffset" => self.y_offset,
    "Unit" => self.unit,
    "IgnoreIfNotPresent" => self.ignore_if_not_present?
  }.delete_if{|key, value| value.nil?}
end