NativeElixirPdfUtilities.Limits (native_elixir_pdf_utilities v1.0.0)

View Source

Runtime resource limits used by PDF parsing, information access, text extraction, merging, page transforms, splitting, and HTML-to-PDF rendering.

Applications can override individual defaults in config/config.exs or config/runtime.exs:

config :native_elixir_pdf_utilities,
  limits: [
    max_svg_bytes: 10_000_000,
    max_svg_raster_dimension: 16_284
  ]

Configuration is validated when the library application starts. Values are process-wide, and changing them requires restarting the application.

Summary

Types

A configurable resource-limit name.

t()

The complete validated resource-limit configuration.

Functions

Returns the library's built-in resource limits.

Returns the effective resource limits loaded for this application instance.

Types

key()

@type key() ::
  :max_pdf_attachments
  | :max_aggregate_html_source_bytes
  | :max_aggregate_css_source_bytes
  | :max_html_source_bytes
  | :max_css_source_bytes
  | :max_html_nodes
  | :max_html_depth
  | :max_css_rules
  | :max_css_work
  | :max_layout_boxes
  | :max_rendered_text_bytes
  | :max_layout_text_work
  | :max_layout_measurement_cache_bytes
  | :max_layout_measurement_cache_entries
  | :max_table_grid_work
  | :max_rendered_pages
  | :max_rendered_pdf_bytes
  | :max_font_source_bytes
  | :max_aggregate_font_source_bytes
  | :max_font_count
  | :max_font_candidates
  | :max_font_discoveries
  | :max_font_cache_bytes
  | :max_system_font_cache_bytes
  | :max_pdf_attachment_bytes
  | :max_pdf_attachment_total_bytes
  | :max_mime_container_bytes
  | :max_mime_container_entries
  | :max_appearance_text_bytes
  | :max_appearance_widgets
  | :max_pdf_form_fields
  | :max_pdf_form_depth
  | :max_pdf_form_text_bytes
  | :max_svg_nodes
  | :max_svg_depth
  | :max_svg_path_bytes
  | :max_svg_filter_primitives
  | :max_svg_references
  | :max_svg_output_bytes
  | :max_svg_bytes
  | :max_svg_raster_dimension
  | :max_svg_raster_pixels
  | :max_png_working_bytes
  | :max_image_count
  | :max_image_source_bytes
  | :max_aggregate_image_source_bytes
  | :max_decoded_image_bytes
  | :max_aggregate_decoded_image_bytes
  | :max_background_image_tiles
  | :max_layout_cardinality
  | :max_css_variable_bytes
  | :max_css_variable_total_bytes
  | :max_css_variable_work
  | :max_css_variable_depth
  | :max_css_numeric_magnitude
  | :max_pdf_reader_decoded_bytes
  | :max_pdf_reader_tokens
  | :max_pdf_reader_values
  | :max_pdf_reader_work
  | :max_pdf_container_entries
  | :max_pdf_numeric_token_bytes
  | :max_pdf_input_bytes
  | :max_pdf_numeric_magnitude
  | :max_pdf_objects
  | :max_pdf_object_stream_entries
  | :max_pdf_pages
  | :max_pdf_page_tree_depth
  | :max_pdf_reference_chain_depth
  | :max_pdf_reference_resolution_work
  | :max_pdf_value_depth
  | :max_pdf_decoded_stream_bytes
  | :max_pdf_decompression_ratio
  | :max_pdf_xref_length_candidates
  | :max_pdf_xref_revisions
  | :max_pdf_info_value_bytes
  | :max_pdf_info_total_bytes
  | :max_pdf_outline_items
  | :max_pdf_outline_depth
  | :max_pdf_outline_title_bytes
  | :max_pdf_outline_total_title_bytes
  | :max_pdf_name_tree_nodes
  | :max_pdf_named_destinations
  | :max_stamp_text_bytes
  | :max_stamp_decoded_content_bytes
  | :max_merge_inputs
  | :max_assembled_pdf_bytes
  | :max_aggregate_merge_input_bytes
  | :max_merged_objects
  | :max_merged_pages
  | :max_split_outputs
  | :max_split_object_writes
  | :max_aggregate_split_output_bytes
  | :max_extracted_text_bytes
  | :max_cmap_expanded_bytes
  | :max_text_decoded_content_bytes
  | :max_text_parsed_instructions
  | :max_text_stream_uses
  | :max_text_instruction_uses
  | :max_text_form_expansions
  | :max_text_spans
  | :max_text_layout_whitespace_bytes
  | :max_cmap_work
  | :max_cmap_bytes
  | :max_cmap_entries
  | :max_cid_width_entries
  | :max_form_xobject_depth
  | :max_font_kerning_pairs
  | :max_font_cmap_work
  | :max_font_subset_work
  | :max_font_cache_entries
  | :max_system_font_cache_entries

A configurable resource-limit name.

t()

@type t() :: %{required(key()) => pos_integer()}

The complete validated resource-limit configuration.

Functions

defaults()

@spec defaults() :: t()

Returns the library's built-in resource limits.

effective()

@spec effective() :: t()

Returns the effective resource limits loaded for this application instance.