Class: Xrechnung::Attachment

Inherits:
Object
  • Object
show all
Includes:
MemberContainer
Defined in:
lib/xrechnung/attachment.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from MemberContainer

#[], #[]=, included, #initialize

Instance Attribute Details

#filenameString

Returns:

  • (String)


13
# File 'lib/xrechnung/attachment.rb', line 13

member :filename, type: String

#mime_codeString

Returns:

  • (String)


9
# File 'lib/xrechnung/attachment.rb', line 9

member :mime_code, type: String

Instance Method Details

#to_xml(xml) ⇒ Object

noinspection RubyResolve



18
19
20
21
22
23
24
25
# File 'lib/xrechnung/attachment.rb', line 18

def to_xml(xml)
  xml.cac :Attachment do
    xml.cbc :EmbeddedDocumentBinaryObject,
      Base64.strict_encode64(payload),
      mimeCode: mime_code,
      filename: filename
  end
end