/* BEGIN INCLUDE FILE linus_report_structures.incl.pl1 Written - Al Dupuis - August 1983 */ /* format: off */ %skip (1); /* Used in column_info.alignment and column_info.linus_data_type */ %skip (1); dcl BIT_DATA_TYPE fixed bin static int options (constant) init (1); dcl BOTH_ALIGNMENT fixed bin static int options (constant) init (1); dcl CENTER_ALIGNMENT fixed bin static int options (constant) init (2); dcl CHAR_DATA_TYPE fixed bin static int options (constant) init (2); dcl DECIMAL_ALIGNMENT fixed bin static int options (constant) init (3); dcl DECIMAL_DATA_TYPE fixed bin static int options (constant) init (3); dcl LEFT_ALIGNMENT fixed bin static int options (constant) init (4); dcl NUMERIC_DATA_TYPE fixed bin static int options (constant) init (4); dcl RIGHT_ALIGNMENT fixed bin static int options (constant) init (5); %skip (3); dcl 1 column_info aligned based (column_ip), 2 flags, 3 folding_is_fill bit (1) unaligned, /* fill or truncate */ 3 outline bit (1) unaligned, /* on means the display has been suppressed */ 3 editing bit (1) unaligned, /* on means there is an editing request */ 3 restore_editing bit (1) unaligned, /* used to toggle the editing bit */ 3 available bit (32) unaligned, 2 order fixed bin, /* as specified by the user */ 2 input_column fixed bin, /* # of the column in the table */ 2 output_column fixed bin, /* # of the column on the page */ 2 output_line fixed bin, /* within the block */ 2 starting_position fixed bin, /* within the page width */ 2 width fixed bin, /* in characters */ 2 alignment fixed bin, /* set to one of the above alignment constants */ 2 decimal_position fixed bin, /* only needed for decimal alignment */ 2 linus_data_type fixed bin, /* set to one of the above data type constants */ 2 editing_string_length fixed bin (21), /* before evaluation */ 2 editing_string_result_length fixed bin (21), /* after evaluation */ 2 editing_string_ptr ptr, /* before evaluation */ 2 editing_string_result_ptr ptr, /* after evaluation */ 2 prefix_character char (1) varying; /* column prefix */ dcl column_ip ptr; %skip (3); dcl 1 columns_info aligned based (columns_ip), /* an array of column_info's */ 2 number_of_columns fixed bin, 2 columns (initialize_number_of_columns refer (columns_info.number_of_columns)) like column_info; dcl columns_ip ptr; %page; dcl 1 column_map (column_map_number_of_columns) aligned based (column_mp), 2 present bit (1), /* the column is present in the list */ 2 position fixed bin; /* position where this column was found in the list */ dcl column_map_number_of_columns fixed bin; dcl column_mp ptr; %skip(3); dcl 1 count_columns_info like columns_info based (count_columns_ip); dcl count_columns_ip ptr; %skip(3); dcl 1 count_info like total_info based (count_ip); dcl count_ip ptr; %skip (3); /* Used to access the current row from the table */ dcl current_row_value char (table_info.row_value_length) based (status.current_row_ptr); %skip (3); /* Used to pick up the value before or after evaluation */ dcl editing_string_result char (editing_string_rl) based (editing_string_rp); dcl editing_string_rl fixed bin; dcl editing_string_rp ptr; %skip (3); dcl editing_strings_next_byte fixed bin (21); /* Used to store editing strings before and after evaluation. */ dcl editing_strings_temp_seg char (maximum_segment_size) based (editing_strings_tsp); dcl editing_strings_temp_seg_as_an_array (maximum_segment_size) char (1) based (editing_strings_tsp); dcl editing_strings_tsp ptr; %page; dcl 1 format_report_info aligned based (format_report_ip), 2 flags, 3 unlimited_page_length bit (1) unaligned, /* -page_length equal to zero */ 3 unlimited_page_width bit (1) unaligned, /* -page_width equal to zero */ 3 page_header_is_defined bit (1) unaligned, /* -page_header_value */ 3 group_header_is_defined bit (1) unaligned, /* -group_header_value */ 3 group_header_trigger_is_defined bit (1) unaligned, /* -group_header_trigger */ 3 title_block_is_defined bit (1) unaligned, /* -title_line */ 3 row_header_is_defined bit (1) unaligned, /* -row_header_value */ 3 row_value_is_defined bit (1) unaligned, /* if all of the columns weren't excluded */ 3 row_footer_is_defined bit (1) unaligned, /* -row_footer_value */ 3 group_footer_is_defined bit (1) unaligned, /* -group_footer_value */ 3 group_footer_trigger_is_defined bit (1) unaligned, /* -group_footer_trigger */ 3 page_footer_is_defined bit (1) unaligned, /* -page_footer_value */ 3 editing_is_defined bit (1) unaligned, /* -editing */ 3 exclude_is_defined bit (1) unaligned, /* -exclude */ 3 group_is_defined bit (1) unaligned, /* -group */ 3 outline_is_defined bit (1) unaligned, /* -outline */ 3 page_break_is_defined bit (1) unaligned, /* -page_break */ 3 subtotal_is_defined bit (1) unaligned, /* -subtotal */ 3 subcount_is_defined bit (1) unaligned, /* -subcount */ 3 total_is_defined bit (1) unaligned, /* -total */ 3 count_is_defined bit (1) unaligned, /* -count */ 3 available bit (15) unaligned, 2 page_width fixed bin, /* as given by the user */ 2 page_length fixed bin, /* as given by the user */ 2 number_of_formatted_rows fixed bin (35), /* updated at the end of each page */ 2 editing_strings_next_available_byte fixed bin (21), /* beginning of temp space for execution */ 2 headers_next_available_byte fixed bin (21), /* beginning of temp space for execution */ 2 report_iocb_ptr ptr, /* for saving copies of the page */ 2 table_info_ptr ptr, /* to avoid repetitive calls to linus_table$info */ 2 format_document_op ptr, /* format_document_options structure */ 2 page_info_ptr ptr, /* page_info structure */ 2 copy_of_page_info_ptr ptr, /* version of page_info structure that can be changed */ /* after each page */ 2 formatted_page_info_ptr ptr, /* formatted_page_info structure */ 2 overstrike_info_ptr ptr, /* page_overstrike_info structure */ 2 status_ptr ptr, /* status structure */ 2 template_map_ptr ptr, /* template_map array */ 2 page_header_info_ptr ptr, /* header_info structure */ 2 page_footer_info_ptr ptr, /* header_info structure */ 2 group_header_info_ptr ptr, /* header_info structure */ 2 group_footer_info_ptr ptr, /* header_info structure */ 2 group_header_trigger_info_ptr ptr, /* group_info structure */ 2 group_footer_trigger_info_ptr ptr, /* group_info structure */ 2 row_header_info_ptr ptr, /* header_info structure */ 2 row_footer_info_ptr ptr, /* header_info structure */ 2 title_block_columns_info_ptr ptr, /* title_block_columns_info structure */ 2 title_block_info_ptr ptr, /* title_block_info structure */ 2 input_columns_info_ptr ptr, /* input_columns_info structure */ 2 input_columns_order_ptr ptr, /* input_columns_order array */ 2 output_columns_info_ptr ptr, /* output_columns_info structure */ 2 group_info_ptr ptr, /* group_info structure */ 2 outline_info_ptr ptr, /* outline_info structure */ 2 page_break_info_ptr ptr, /* page_break_info structure */ 2 subtotal_info_ptr ptr, /* subtotal_info structure */ 2 subcount_info_ptr ptr, /* subcount_info structure */ 2 total_info_ptr ptr, /* total_info structure */ 2 count_info_ptr ptr, /* count_info structure */ 2 row_value_template_info_ptr ptr, /* row_value_template_info structure */ 2 generic_template_ptr ptr, /* generic_template char string */ 2 header_part_delimiter char (1) unaligned, /* delimits the different portions of a header/footer */ 2 truncation_indicator char (32) varying unaligned, /* used to indicate that truncation has occured */ 2 report_directory_name char (168) unaligned, /* dir where we place copies of the page */ 2 report_entry_name char (32) unaligned; /* entry name portion of above */ dcl format_report_ip ptr; %skip(1); /* used to format page/row headers and footers */ dcl generic_template char (generic_template_length) based (generic_tp); dcl generic_template_length fixed bin; dcl generic_tp ptr; %skip (3); /* these columns form a group of rows and are used with outlining, etc. */ dcl 1 group_info aligned based (group_ip), 2 number_of_columns_to_group fixed bin, 2 column_number (gi_init_number_of_columns_to_group refer (group_info.number_of_columns_to_group)) fixed bin; dcl gi_init_number_of_columns_to_group fixed bin; dcl group_ip ptr; %skip (3); dcl headers_next_byte fixed bin (21); /* used to hold the page/row headers/footers, and temp space for totals/subtotals. */ dcl headers_temp_seg char (maximum_segment_size) based (headers_tsp); dcl headers_temp_seg_as_an_array (maximum_segment_size) char (1) based (headers_tsp); dcl headers_tsp ptr; %skip (3); dcl 1 header_info aligned based (header_ip), 2 number_of_lines fixed bin, /* number of header lines typed in by the user */ 2 maximum_number_of_parts fixed bin, /* 3 parts maximum (left, right, and center) */ 2 lines (hi_init_number_of_lines refer (header_info.number_of_lines)), 3 parts (hi_init_maximum_number_of_parts refer (header_info.maximum_number_of_parts)), 4 flags, 5 present bit (1) unaligned, /* this particular part is defined */ 5 active bit (1) unaligned, /* and it contains active functions */ 5 available bit (34) unaligned, 4 index fixed bin (21), /* before evaluation */ 4 length fixed bin (21), /* before evaluation */ 4 starting_position fixed bin, /* within the page width */ 4 width fixed bin, /* within the page width */ 4 alignment fixed bin; /* left, right, or center */ dcl header_ip ptr; dcl hi_init_maximum_number_of_parts fixed bin; dcl hi_init_number_of_lines fixed bin; %skip (3); dcl initialize_number_of_columns fixed bin; /* columns_info refer extent */ %skip (3); dcl 1 input_columns_info aligned like columns_info based (input_columns_ip); /* the columns in the table */ dcl input_columns_ip ptr; %skip (3); dcl input_columns_order (input_columns_info.number_of_columns) fixed bin based (input_columns_op); dcl input_columns_op ptr; %skip (3); dcl maximum_segment_size fixed bin (21); /* in characters */ %skip (3); /* Used to access the next row from the table */ dcl next_row_value char (table_info.row_value_length) based (status.next_row_ptr); %skip (3); dcl 1 outline_info aligned based (outline_ip), /* who gets oulining attempted */ 2 maximum_number_of_single_columns fixed bin, 2 maximum_number_of_grouping_columns fixed bin, 2 number_of_single_columns fixed bin, /* columns who are not a member of the group */ 2 number_of_grouping_columns fixed bin, /* columns who are a member of the group */ 2 single_columns (oi_init_maximum_number_of_single_columns refer ( outline_info.maximum_number_of_single_columns)) fixed bin, 2 grouping_columns (oi_init_maximum_number_of_grouping_columns refer ( outline_info.maximum_number_of_grouping_columns)) fixed bin; dcl oi_init_maximum_number_of_grouping_columns fixed bin; dcl oi_init_maximum_number_of_single_columns fixed bin; dcl outline_ip ptr; %skip (3); dcl 1 output_columns_info like columns_info based (output_columns_ip); /* the columns that will go on the page */ dcl output_columns_ip ptr; %skip (3); /* these columns will be checked to determine if a page break is required */ dcl 1 page_break_info aligned based (page_break_ip), 2 number_of_columns fixed bin, 2 columns (pbi_init_number_of_columns refer ( page_break_info.number_of_columns)) bit (1) unaligned; dcl page_break_ip ptr; dcl pbi_init_number_of_columns fixed bin; %skip (3); /* Used to access the previous row from the table */ dcl previous_row_value char (table_info.row_value_length) based (status.previous_row_ptr); %skip (3); /* The templates for the row value (also used for titles, subtotals, and totals.) */ dcl 1 row_value_template_info like template_info based (row_value_template_ip); dcl row_value_template_ip ptr; %skip (3); /* main execution control structure for linus_fr_build_page */ dcl 1 status aligned based (status_pointer), 2 flags, 3 still_formatting_detail_blocks bit (1), /* turned on while we are doing detail blocks */ 3 first_row_of_report bit (1), /* turned on when we are on the first row of a report */ 3 last_row_of_report bit (1), /* turned on when we are on the last row of a report */ 3 first_row_on_page bit (1), /* turned on when we are on the 1st row of a page */ 3 page_overflow bit (1), /* turned on when we are backing up */ 3 subtotals_ejection_in_progress bit (1), /* turned on when subtotals are being ejected */ 3 subcounts_ejection_in_progress bit (1), /* turned on when subcounts are being ejected */ 3 totals_ejection_in_progress bit (1), /* turned on when totals are being ejected */ 3 counts_ejection_in_progress bit (1), /* turned on when counts are being ejected */ 3 header_being_evaluated bit (1), /* turned on during header evaluation */ 3 detail_block_used_some_lines bit (1), /* turned on when a row header/footer/value/subtotal/total uses a line */ 3 row_has_been_processed_before bit (1), /* turned on when this row has been backed out of the previous page */ 3 last_pass bit (1), /* true if this is the last pass */ 2 previous_row_ptr ptr, /* points to the previous row (or null) */ 2 current_row_ptr ptr, /* points to the current row */ 2 next_row_ptr ptr, /* points to the next row (or null) */ 2 total_number_of_rows_used fixed bin, /* total # per page, used to make sure we don't */ /* backup over the 1st row */ 2 current_pass_number fixed bin, /* [display_builtins current_pass_number] */ 2 current_row_number fixed bin (35), /* [display_builtins current_row_number] */ 2 current_column_number fixed bin, /* set to the current output column during row evaluation */ 2 current_page_number fixed bin (21), /* [display_builtins page_number] */ 2 current_line_on_page fixed bin, /* this is where the next thing is placed on the page */ 2 remaining_lines_on_page fixed bin, /* used in estimating if something will fit */ 2 highest_row_formatted fixed bin, /* used to keep track of rows backed out of the page */ 2 current_header_line fixed bin, /* set to the current header line during header evaluation */ 2 current_header_part fixed bin, /* set to the current header part during header evaluation */ 2 number_of_lines_needed_for_detail_block fixed bin, /* sum of row header, footer, and value */ 2 number_of_lines_needed_for_row_header fixed bin, /* may be zero */ 2 number_of_lines_needed_for_row_value fixed bin, /* may be zero */ 2 number_of_lines_needed_for_row_footer fixed bin, /* may be zero */ 2 number_of_lines_needed_for_page_footer fixed bin, /* may be zero */ 2 number_of_lines_needed_for_group_header fixed bin, /* may be zero */ 2 number_of_lines_needed_for_group_footer fixed bin, /* may be zero */ 2 last_row_number fixed bin (35), /* zero unless multi-pass */ 2 last_page_number fixed bin, /* zero unless multi-pass mode */ 2 object_being_evaluated char (16) varying; /* "page header", "row value", etc. */ dcl status_pointer ptr; %skip (3); dcl 1 subcount_columns_info like columns_info based (subcount_columns_ip); dcl subcount_columns_ip ptr; %skip(3); dcl 1 subcount_generation_info like subtotal_generation_info based (subcount_generation_ip); dcl subcount_generation_ip ptr; %skip(3); dcl 1 subcount_info like subtotal_info based (subcount_ip); dcl subcount_ip ptr; %skip (3); dcl 1 subtotal_columns_info like columns_info based (subtotal_columns_ip); dcl subtotal_columns_ip ptr; %skip (3); /* Used to restore subtotals when backing up on a page. */ dcl 1 subtotal_generation_info aligned based (subtotal_generation_ip), 2 maximum_number_of_generation_blocks fixed bin, /* maximum number of subtotals possibly generated per page + 1 */ 2 number_of_subtotals fixed bin, /* # of subtotals we're taking */ 2 current_generation_block fixed bin, /* slot for next subtotal generation */ 2 generations (0:sgi_init_number_of_generations refer (subtotal_generation_info.maximum_number_of_generation_blocks)), 3 subtotals (sgi_init_number_of_subtotals /* value of the subtotals when the break occured */ refer (subtotal_generation_info.number_of_subtotals)) float dec (59); dcl sgi_init_number_of_generations fixed bin; dcl sgi_init_number_of_subtotals fixed bin; dcl subtotal_generation_ip ptr; %skip (3); dcl 1 subtotal_info aligned based (subtotal_ip), 2 columns_info_ptr ptr, /* points to subtotal_columns_info structure */ 2 subtotal_generation_info_ptr ptr, /* points to subtotal_generations_info structure */ 2 number_of_columns_to_subtotal fixed bin, /* the number of subtotals */ 2 highest_level fixed bin, /* the largest number of different subtotals on a single column */ 2 current_level fixed bin, /* the current level of subtotals being evaluated */ 2 columns (si_init_number_of_columns_to_subtotal refer (subtotal_info.number_of_columns_to_subtotal)), 3 flags, 4 reset bit (1) unaligned, /* reset or running subtotals */ 4 group_column bit (1) unaligned, /* on means the watch column is a grouping column */ 4 available bit (34) unaligned, 3 input_column fixed bin, /* # of the input column for accumulations */ 3 watch_column fixed bin, /* # of the column to watch for generation */ 3 level fixed bin, /* different subtotals on the same column receive higher level numbers */ 3 ioa_string char (5) varying, /* used to edit the "subtotal" field */ 3 subtotal float dec (59); /* used to hold the subtotal until it needs /* /* to be placed on the page */ dcl si_init_number_of_columns_to_subtotal fixed bin; dcl subtotal_ip ptr; %skip (3); dcl 1 template_info aligned based (template_ip), /* templates that are laid down before the column values */ 2 template_width fixed bin, /* how wide they are */ 2 number_of_templates fixed bin, /* how many there are */ 2 templates (ti_init_number_of_templates refer (template_info.number_of_templates)) /* the templates */ char (ti_init_template_width refer (template_info.template_width)); dcl ti_init_number_of_templates fixed bin; dcl template_ip ptr; dcl ti_init_template_width fixed bin; %skip (3); /* used to determine which templates have been placed */ dcl template_map (template_map_number_of_bits) bit (1) unaligned based (template_mp); dcl template_mp ptr; dcl template_map_number_of_bits fixed bin; dcl template_map_defined_as_a_string bit (template_map_number_of_bits) based (template_mp); %skip (3); dcl template char (template_length) based (template_ptr); dcl template_length fixed bin; dcl template_ptr ptr; %skip (3); dcl 1 title_block_columns_info like columns_info based (title_block_columns_ip); /* output columns for the titles */ dcl title_block_columns_ip ptr; %skip (3); /* holds the formatted title block after page 1 is finished */ dcl 1 title_block_info aligned based (title_block_ip), 2 number_of_lines fixed bin, /* how many lines there are */ 2 line_length fixed bin, /* how long the lines are */ 2 lines (tbi_init_number_of_lines refer ( /* the formatted lines */ title_block_info.number_of_lines)) char (tbi_init_line_length refer ( title_block_info.line_length)); dcl tbi_init_line_length fixed bin; dcl tbi_init_number_of_lines fixed bin; dcl title_block_ip ptr; %skip (3); dcl 1 total_columns_info like columns_info based (total_columns_ip); /* output_columns_info for totals */ dcl total_columns_ip ptr; %skip (3); dcl 1 total_info aligned based (total_ip), 2 columns_info_ptr ptr, /* points to total_columns_info structure */ 2 number_of_columns_to_total fixed bin, /* # to total */ 2 columns (ti_init_number_of_columns_to_total refer (total_info.number_of_columns_to_total)), 3 input_column fixed bin, /* the input column number */ 3 ioa_string char (5) varying, /* used to edit the "total" field */ 3 total float dec (59); /* used to hold the total until it's placed on the page */ dcl ti_init_number_of_columns_to_total fixed bin; dcl total_ip ptr; %skip (1); /* END INCLUDE FILE linus_report_structures.incl.pl1 */ */ ----------------------------------------------------------- Historical Background This edition of the Multics software materials and documentation is provided and donated to Massachusetts Institute of Technology by Group Bull including Bull HN Information Systems Inc. as a contribution to computer science knowledge. This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell Bull Inc., Groupe Bull and Bull HN Information Systems Inc. to the development of this operating system. Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for managing computer hardware properly and for executing programs. Many subsequent operating systems incorporated Multics principles. Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . ----------------------------------------------------------- Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without fee is hereby granted,provided that the below copyright notice and historical background appear in all copies and that both the copyright notice and historical background and this permission notice appear in supporting documentation, and that the names of MIT, HIS, Bull or Bull HN not be used in advertising or publicity pertaining to distribution of the programs without specific prior written permission. Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. Copyright 2006 by Bull HN Information Systems Inc. Copyright 2006 by Bull SAS All Rights Reserved */