Class: Xberg::ChunkingReasonLargeAndManyPages

Inherits:
Data
  • Object
show all
Extended by:
T::Sig
Includes:
ChunkingReason
Defined in:
lib/xberg/native.rb

Overview

Both size and page count exceed thresholds.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#page_countObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



4785
4786
4787
# File 'lib/xberg/native.rb', line 4785

def page_count
  @page_count
end

#size_bytesObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



4785
4786
4787
# File 'lib/xberg/native.rb', line 4785

def size_bytes
  @size_bytes
end

Class Method Details

.from_hash(hash) ⇒ Object



4808
4809
4810
# File 'lib/xberg/native.rb', line 4808

def self.from_hash(hash)
  new(size_bytes: hash[:size_bytes] || hash["size_bytes"], page_count: hash[:page_count] || hash["page_count"])
end

Instance Method Details

#large_and_many_pages?Boolean

Returns:

  • (Boolean)


4804
4805
4806
# File 'lib/xberg/native.rb', line 4804

def large_and_many_pages? = true
# @param hash [Hash] deserialized from the native extension
# @return [self]

#large_file?Boolean

Returns:

  • (Boolean)


4798
# File 'lib/xberg/native.rb', line 4798

def large_file? = false

#many_pages?Boolean

Returns:

  • (Boolean)


4800
# File 'lib/xberg/native.rb', line 4800

def many_pages? = false

#ocr_required?Boolean

Returns:

  • (Boolean)


4802
# File 'lib/xberg/native.rb', line 4802

def ocr_required? = false