Modules

ModuleSource FileDescription
parquet parquet.f90

The public API of parquet-fortran, and the only module a user needs to name: a single use parquet brings the whole library into scope.

Read more…
parquet_argsort parquet_argsort.f90

pf_argsort over plain Fortran arrays, and the sort engine underneath it.

Read more…
   parquet_argsort_engine parquet_argsort_engine.f90

The serial core of the pure-Fortran sort engine: the ordering, and the introsort over it.

Read more…
   parquet_argsort_kernel parquet_argsort_kernel.f90

The six intrinsic pf_argsort specifics, their key extraction, and the engine dispatch.

Read more…
parquet_columns parquet_columns.f90

Type-erased, whole-column value storage shared by parquet_table and (later) the list/map/struct container column types.

Read more…
   parquet_columns_access parquet_columns_access.f90

Per-kind value access for parquet_column: get_at, set_at, set_all and data_ptr over every array kind. The string kinds live in parquet_columns_string instead, because they delegate to parquet_string_column (DD1).

Read more…
   parquet_columns_mutate parquet_columns_mutate.f90

Per-kind value append for parquet_column, plus the four kind-dispatched storage helpers (gather_storage, grow_storage, copy_storage, paste_storage) that the hand-written structural operations in parquet_columns_structural are built on -- so reindex, delete_by_mask, append, append_nulls, paste and deep_copy each exist ONCE, kind-agnostically, instead of eighteen times.

   parquet_columns_string parquet_columns_string.f90

The string kinds of parquet_column (PK_STRING, PK_STRING_VEC), which are the one place the type-erased storage is not a Fortran array.

Read more…
   parquet_columns_structural parquet_columns_structural.f90

Lifecycle and structural mutation for parquet_column: init, clear, deep_copy, the unit accessors, and the four row-set operations append, append_nulls, delete_by_mask and reindex.

Read more…
   parquet_columns_util parquet_columns_util.f90

Shared internal helpers for parquet_column: argument guards, the validity-bitmap primitives, and the two kind-category predicates.

Read more…
   parquet_columns_validity parquet_columns_validity.f90

Kind-dispatched validity for parquet_column (RF8).

Read more…
parquet_core parquet_core.f90

Core reader/writer implementation for Apache Parquet files: schema construction/validation from MAML, writers/readers, row filtering, quality-control (qc:) enforcement, and flat key-value table metadata. Submodules parquet_write.f90/parquet_read.f90/parquet_metadata.f90 hold the bodies of the module procedures declared in the interface block below.

Read more…
   parquet_metadata parquet_metadata.f90

Bodies of the schema-building module procedures declared in parquet_core.f90's interface block: parsing a MAML into a parquet_schema (parquet_parse_maml), building a schema from scratch (schema%init/%add_field), and the central parquet_parse_maml_lines parser, plus the private MAML-section helpers (keyarray:/DOI/depends/keywords/col_map/protected_cols) it depends on.

      parquet_metadata_base parquet_metadata_base.f90

Generic parquet_column_info/parquet_table_metadata plumbing shared by both the write (MAML-build) and read sides: the base add_metadata family, per-field column_info lookups/toggles, and low-level MAML string helpers (parquet_split_key_value/parquet_unquote/parquet_to_lower) reused across submodules.

      parquet_metadata_get parquet_metadata_get.f90

Everything here backs the parquet_get_metadata generic (declared in parquet_core.f90): reader%metadata is populated once, by parquet_open_reader (parquet_read.f90) copying the Arrow schema's flat key-value metadata, so every call here only scans that in-memory array -- it never touches the file. Messages follow the ": " error stop convention used throughout this module.

      parquet_metadata_maml parquet_metadata_maml.f90

MAML-format-specific validation: the declarative schema of every top-level MAML section and its allowed sub-keys plus the validator and its private helpers that check a raw MAML's section/sub-key names against it (presence only, not values); full-schema structural validation (parquet_validate_maml); cross-checking a user MAML against a base schema (parquet_validate_user_maml); loading MAML/qc-maml files from disk; and qc-maml field parsing/validation for read-time quality control. Merges what used to be parquet_metadata_sections.f90 and parquet_metadata_validate.f90.

   parquet_write parquet_write.f90

Writer lifecycle (open/close/new_row_group/finish_row_group) and the type-generic shared helpers every write-specifics child (parquet_write_numeric/ _string/_temporal) reaches by host association: schema/column-info lookups, row-count and row-mask bookkeeping, output-name resolution, qc: integer-count text formatting (shared by numeric and string qc: reports), and the write_maml=.true. sidecar .maml.

      parquet_write_numeric parquet_write_numeric.f90

Numeric write specifics (int32/int64/float32/float64/logical, scalar and matrix, whole-column and row-group-chunked): bodies of the module procedures declared in parquet_core.f90's interface block, plus the numeric-only private helpers (schema-type widening/narrowing, append, qc: enforcement, qc: numeric-bound satisfaction, qc: real-value text formatting) they depend on.

      parquet_write_string parquet_write_string.f90

String write specifics (scalar and matrix, whole-column and row-group-chunked, plus the fixed-width "compact" variants): bodies of the module procedures declared in parquet_core.f90's interface block, plus the string-only private qc: enforcement/bound-satisfaction helpers they depend on.

      parquet_write_temporal parquet_write_temporal.f90

Temporal (date/time/timestamp) write specifics, scalar and matrix, whole- column and row-group-chunked: bodies of the module procedures declared in parquet_core.f90's interface block, plus the temporal-only private helpers (preamble/unit-resolution/validity/flat-write workers) they depend on.

   parquet_read parquet_read.f90

Reader lifecycle (open/close), filter/qc machinery, metadata population, row-group resolution, and the type-generic shared helpers every read-specifics child (parquet_read_numeric/_string/_temporal) reaches by host association: validity-buffer construction, reader/column/row-group existence checks, fixed-width text packing for the filter/qc C++ API, and the whole-column-read-avoidance row-group helpers.

      parquet_read_filter parquet_read_filter.f90

Filter-expression parsing: turns one parquet_filter%add rule ("(ra > 180 and dec <= 0) or id is_null") into the packed leaf arrays plus the postfix (RPN) node list the C++ evaluator runs (see parquet_reader_set_filter in parquet_wrapper.cpp). Purely syntactic -- no schema access at all, so nothing here can tell whether a column exists or whether a value suits its type; that validation stays C++-side, where the schema is.

Read more…
      parquet_read_numeric parquet_read_numeric.f90

Numeric read specifics (int32/int64/float32/float64/logical: column_1d, array_full, array_row_mode[_row_index], array_element_mode, and column_chunk/array_column_chunk, both row-group-index kinds): bodies of the module procedures declared in parquet_core.f90's interface block, plus the numeric-only private per-mode worker helpers they depend on.

      parquet_read_sort parquet_read_sort.f90

Sort-key parsing: turns one parquet_sortkey%add key ("ra asc", "-dec", "main.inner.age") into the column name plus a direction flag the C++ engine takes (see parquet_reader_set_sort in parquet_wrapper.cpp). Purely syntactic -- no schema access at all, so nothing here can tell whether a column exists or whether its type is orderable; that validation stays C++-side, where the schema and the decoded array are.

Read more…
      parquet_read_string parquet_read_string.f90

String read specifics (column_1d, array_full, the fixed-width "compact" column form, array_row_mode[_row_index], array_element_mode, and column_chunk/array_column_chunk incl. the compact chunked form): bodies of the module procedures declared in parquet_core.f90's interface block, plus the string-only private per-mode worker helpers they depend on.

      parquet_read_temporal parquet_read_temporal.f90

Temporal (date/time/timestamp) read specifics: column_1d, array_full, column_chunk/array_column_chunk (both row-group-index kinds), array_row_mode[_row_index], and array_element_mode: bodies of the module procedures declared in parquet_core.f90's interface block, plus the temporal-only private per-mode worker helpers they depend on.

parquet_expkey parquet_expkey.f90

The frozen -log(u) transform behind pf_weighted_permutation's exponential race.

Read more…
parquet_io parquet_io.f90

Reading and writing Parquet files, and nothing else: the minimal supported entry point for a program that opens a file, moves columns in or out of it, and closes it again.

Read more…
parquet_maml_base parquet_maml_base.f90

Base-library MAML fixtures: embeds every .maml file under schemas/ bundled with this library as a compiled-in string array, addressable by filename via get_parquet_maml, plus the shared parquet_maml_file type and its add_col_qc/set_col_qc qc-maml builders.

   parquet_maml_base_add_col_qc parquet_maml_base_add_col_qc.f90

Hand-written submodule of parquet_maml_base (NOT generated). Implements the parquet_maml_file%add_col_qc and %set_col_qc (both subroutines) type-bound procedures, whose deferred module-procedure interfaces are declared in the (generated) src/parquet_maml_base.f90. Both share one worker (add_col_qc_impl) and differ only in how the parsed column name is returned: add_col_qc via an optional out-argument, set_col_qc via its own intent(inout) argument (so a caller can reuse one variable in place, which add_col_qc's two-argument form cannot do due to intent(out)/intent(in) aliasing).

Read more…
parquet_random parquet_random.f90

Counter-based random numbers: reproducible under any OpenMP schedule, at any thread count.

Read more…
parquet_sampling parquet_sampling.f90

Random selection from a population: permutations, subsets, resampling, and weighted draws.

Read more…
parquet_settings parquet_settings.f90

Process-global settings for parquet-fortran: the parameters that apply to the whole library rather than to one reader, writer or table, collected in a single place a program can read and change.

Read more…
parquet_settings_base parquet_settings_base.f90

The settings an Arrow-free module owns: state, getter and setter.

Read more…
parquet_sorting parquet_sorting.f90

Sorting for plain Fortran arrays and for this library's own column types.

Read more…
   parquet_sorting_argsort parquet_sorting_argsort.f90

pf_argsort and pf_sort for the element types that need a parquet column, a packed string store or a temporal element, plus pf_sort for every type and the multi-key pf_sort_keys form.

Read more…
   parquet_sorting_keys parquet_sorting_keys.f90

Turns the element types that need a column, a packed string store or a temporal element into the canonical key form the engine takes, and implements pf_sort_keys.

Read more…
   parquet_sorting_permute parquet_sorting_permute.f90

pf_permute (apply a permutation in place) and pf_is_sorted (test an existing order).

Read more…
   parquet_sorting_reduce parquet_sorting_reduce.f90

pf_minmax, pf_argminmax and pf_merge.

Read more…
   parquet_sorting_search parquet_sorting_search.f90

pf_lower_bound, pf_upper_bound and pf_equal_range -- locating a value in an array that is ALREADY sorted.

Read more…
   parquet_sorting_select parquet_sorting_select.f90

pf_partial_sort and pf_partial_argsort -- ordering only the first n elements.

Read more…
   parquet_sorting_unique parquet_sorting_unique.f90

pf_unique_count, pf_unique and pf_rank -- questions about repeated values.

Read more…
parquet_sorting_oracle parquet_sorting_oracle.f90

The TEST-ONLY C++ sort engine, bound into the argsort tier at run time.

Read more…
parquet_strings parquet_strings.f90

Independent, self-contained module for Parquet BYTE_ARRAY/STRING column storage.

Read more…
parquet_table_example parquet_table_example.f90

Table type generated from the test MAML schema: parquet_table_test, with one accessor per predefined column.

Read more…
parquet_tables parquet_tables.f90

A whole parquet file as one in-memory table: parquet_table.

Read more…
   parquet_tables_access parquet_tables_access.f90

Per-kind value access for parquet_table: the zero-copy pointer path (%col), the widening copy-out (%get) and the copy-back (%set).

   parquet_tables_addcol parquet_tables_addcol.f90

Per-kind %add_column for parquet_table: appends a new in-memory column, taking its kind, width and row count from the values it is given.

   parquet_tables_clone parquet_tables_clone.f90

Copying a parquet_table: %clone (an independent deep copy) and %clone_structure (an empty table with the same columns).

Read more…
   parquet_tables_col parquet_tables_col.f90

parquet_table_col — a resolved handle on one column of a parquet_table.

Read more…
   parquet_tables_colaccess parquet_tables_colaccess.f90

Per-kind value access for parquet_table_col, and the shared bodies the table's own %get_element calls so the two forms cannot answer differently.

Read more…
   parquet_tables_lifecycle parquet_tables_lifecycle.f90

Lifecycle of a parquet_table: opening one from a file, starting an empty in-memory one, destroying one, the blocked intrinsic assignment, and the slot/row bookkeeping that adding a column goes through.

Read more…
   parquet_tables_maml parquet_tables_maml.f90

Read-in (Role-B) MAML support for parquet_table: parsing the extra: remap: block that relabels a file's columns for reading, and building the descriptor slots from it.

Read more…
   parquet_tables_materialize parquet_tables_materialize.f90

Per-kind "read one file column into a parquet_column" for parquet_table.

Read more…
   parquet_tables_mutate parquet_tables_mutate.f90

Mutation that leaves a parquet_table's ROW SET alone: the single-cell validity writers (%set_null, %clear_null, %compact_validity) and the column-structural operations (%drop_column, %rename_column, %copy_column, %cast).

Read more…
   parquet_tables_parallel parquet_tables_parallel.f90

Everything that makes a parquet_table safe to use from more than one thread: the table's own lock, the counters behind the append/read contract, and the shared refusal every structural mutation routes through.

Read more…
   parquet_tables_predefined parquet_tables_predefined.f90

Binding the predefined columns a GENERATED table type declares: %bind_predefined.

Read more…
   parquet_tables_query parquet_tables_query.f90

Introspection and name resolution for parquet_table: the row/column counts, the per-column queries (%kind, %width, %unit, %residency, %is_null), and the shared lookup and guard helpers every value accessor is built on.

Read more…
   parquet_tables_read parquet_tables_read.f90

Turning a parquet file's columns into parquet_column stores: deciding each column's kind from the file schema, driving the per-kind readers, and freeing the Arrow buffers as it goes.

Read more…
   parquet_tables_row parquet_tables_row.f90

The row handle parquet_table_row: making one, resolving a column through it, and the two queries that do not depend on a column's kind. The per-kind %get specifics are generated into parquet_tables_access alongside the table's own accessors.

Read more…
   parquet_tables_rowmutate parquet_tables_rowmutate.f90

Mutation that changes a parquet_table's ROW SET: %filter_rows, %sort_by, %top_n, %delete_rows, %truncate, %append and %append_null_rows.

Read more…
   parquet_tables_slice parquet_tables_slice.f90

Row selection: building a parquet_slice and turning one into the explicit list of rows it picks out. The per-kind copies that consume that list are generated into parquet_tables_access next to the table's own %get.

Read more…
   parquet_tables_sort parquet_tables_sort.f90

Turns a parquet_table's key columns into a row permutation, using the library's own Fortran radix engine -- the SAME engine the read-time sort_by= runs on.

Read more…
   parquet_tables_write parquet_tables_write.f90

Writing a parquet_table back out to a parquet file.

Read more…
parquet_temporal parquet_temporal.f90

Independent, self-contained module providing the element-level Parquet date/time value types.

Read more…
parquet_version parquet_version.f90

The version of parquet-fortran itself, and nothing else.

Read more…
parquet_ziggurat parquet_ziggurat.f90

Layer tables for the Ziggurat normal draw. Data only -- no procedures.

Read more…