Class: PPTX::OPC::BinaryPart

Inherits:
BasePart show all
Defined in:
lib/pptx/opc/binary_part.rb

Direct Known Subclasses

FilePart, S3ObjectPart

Instance Method Summary collapse

Methods inherited from BasePart

#base_xml, #content_type, #part_name, #template

Constructor Details

#initialize(package, original_name) ⇒ BinaryPart

Returns a new instance of BinaryPart.



4
5
6
7
8
# File 'lib/pptx/opc/binary_part.rb', line 4

def initialize(package, original_name)
  name = "ppt/media/binary-#{SecureRandom.hex(10)}#{File.extname(original_name)}"
  super(package, name)
  @original_name = original_name
end

Instance Method Details

#docObject



10
11
12
# File 'lib/pptx/opc/binary_part.rb', line 10

def doc
  throw "Binary parts can't be parsed as XML"
end

#marshalObject



14
15
16
# File 'lib/pptx/opc/binary_part.rb', line 14

def marshal
  throw 'Implement me!'
end