Class: Pdfrb::Model::Type::WebCaptureImageSet
- Inherits:
-
Cos::Stream
- Object
- Object
- Cos::Dictionary
- Cos::Stream
- Pdfrb::Model::Type::WebCaptureImageSet
- Defined in:
- lib/pdfrb/model/type/web_capture_image_set.rb
Overview
WebCaptureImageSet (ISO 32000-1 §14.10.3, PDF 1.3, deprecated PDF 2.0). A spider content set holding captured images. The /O array lists image XObjects; /R gives the crawl depth for each image.
Instance Attribute Summary
Attributes inherited from Cos::Stream
Attributes inherited from Object
Instance Method Summary collapse
-
#content_type ⇒ Object
/CT — optional content type (RFC 2045).
-
#images(document = nil) ⇒ Object
/O — required array of indirect references to images.
-
#set_id ⇒ Object
/ID — required unique identifier.
-
#set_type ⇒ Object
/S — required, fixed "SIS" (Spider Image Set).
-
#timestamp ⇒ Object
/TS — optional date of capture.
-
#type ⇒ Object
/Type — optional, fixed "SpiderContentSet".
Methods inherited from Cos::Stream
#decoded_stream, #encoded_stream=, #initialize
Methods inherited from Cos::Dictionary
#[], #[]=, arlington_available?, arlington_default, arlington_key_to_symbol, arlington_loaded_for?, arlington_mark_loaded, arlington_object, arlington_one_type_to_ruby, arlington_required?, arlington_types_to_ruby, arlington_version, define_field, define_field_from_arlington, #delete, #each, each_field, #each_raw, #empty?, field, #initialize, #key?, #keys, lookup_type, own_fields, #pdf_type, register_type, type_map, #validate
Methods inherited from Object
#==, define_type, #deref, #indirect?, #initialize, #must_be_indirect?, #pdf_type, pdf_type
Constructor Details
This class inherits a constructor from Pdfrb::Model::Cos::Stream
Instance Method Details
#content_type ⇒ Object
/CT — optional content type (RFC 2045).
39 40 41 |
# File 'lib/pdfrb/model/type/web_capture_image_set.rb', line 39 def content_type value[:CT] end |
#images(document = nil) ⇒ Object
/O — required array of indirect references to images.
29 30 31 32 33 34 35 36 |
# File 'lib/pdfrb/model/type/web_capture_image_set.rb', line 29 def images(document = nil) refs = value[:O] return [] unless refs && document arr = refs.is_a?(Pdfrb::Model::PdfArray) ? refs.value : refs arr = [arr] unless arr.is_a?(::Array) arr.filter_map { |r| r.is_a?(Pdfrb::Model::Reference) ? document.object(r) : r } end |
#set_id ⇒ Object
/ID — required unique identifier.
24 25 26 |
# File 'lib/pdfrb/model/type/web_capture_image_set.rb', line 24 def set_id value[:ID] end |
#set_type ⇒ Object
/S — required, fixed "SIS" (Spider Image Set).
19 20 21 |
# File 'lib/pdfrb/model/type/web_capture_image_set.rb', line 19 def set_type value[:S]&.to_sym end |
#timestamp ⇒ Object
/TS — optional date of capture.
44 45 46 |
# File 'lib/pdfrb/model/type/web_capture_image_set.rb', line 44 def value[:TS] end |
#type ⇒ Object
/Type — optional, fixed "SpiderContentSet".
14 15 16 |
# File 'lib/pdfrb/model/type/web_capture_image_set.rb', line 14 def type value[:Type]&.to_sym end |