Mild refactor of get_next

Modified   database/LOGGER/Packages/aop_processor.pkb
--NEW REGEX SECTION - Param searching
--NEW FUNCTION matched_with
--MOD FUNCTION get_next - mild refactor using i_search and i_stop instead of i_go_past and i_consume.
New ability to add annotations.

Modified   database/LOGGER/Packages/aop_processor.pkb
--MOD PROCEDURE AOP_block - now processes tags in the form --####comment1##
--MOD procedure stash_comments_and_quotes - makes sure the the --## are NOT stashed, so AOP_block will recognise it.
Modified   database/LOGGER/UnitTest/aop_test.pkb
Added new examples
  --""This is a special comment
  --??This is a special info
  --!!This is a special warning
  --##This is a special fatal
Fixed failure to recognise "-- comment" and ")"

Modified   database/LOGGER/Packages/aop_processor.pkb
--FIX G_REGEX_END_CASE_EXPR
--FIX G_REGEX_CLOSE_BRACKET
--MOD procedure set_weave_timeout
--Line Count derived from length of CLOB minus length of CLOB-without-CR
--MOD FUNCTION get_next - added i_trim DEFAULT TRUE
-- as temporary measure to fix recognition of G_REGEX_START_SINGLE_COMMENT
-- problem with whitespace
--MOD FUNCTION AOP_pu_params - colour the brackets.
Add a PACKAGE_NAME to the Quick AOP screen and use that as the module_name in AOP code.

Modified   apex/f104/application/pages/page_00021.sql
--NEW field P21_PACKAGE_NAME passed to aop_processor.weave BY process PerformAOP
Modified   database/LOGGER/Packages/aop_processor.pkb
--NEW global g_aop_module_name - used to create l_inject_node BY PROCEDURE AOP_prog_units
--MOD function weave - populates g_aop_module_name with p_package_name or $$plsql_unit (if null)
Creates Note after assignment to a bind variable.

Modified   database/LOGGER/Packages/aop_processor.pkb
--NEW FUNCTION f_colour - used by splice, get_next, restore_comments_and_quotes
--FIX PROCEDURE inject - decrement g_current_pos before injection
--MOD FUNCTION get_next
-- add param i_upper and i_lower for deprecation of get_next_upper and get_next_lower
-- add param i_sub_expr for future MOD to allow return value by sub-expression position
--MOD PROCEDURE AOP_block - find assignment of bind variable and inject a note
Adding warning for a WHEN OTHERS THEN

Modified   database/LOGGER/Packages/aop_processor.pkb
--MOD PROCEDURE AOP_is_as
--Packages don't need to have BEGIN.
--and in this case we don't need the Initialisation node either, so remove it again.

--MOD PROCEDURE AOP_block - add warn_error after WHEN OTHERS THEN
New feature SHOW_ME_LINE - code lines with trailing --@@ are exposed in a comment.

Modified   database/LOGGER/Packages/aop_processor.pkb
--NEW PROCEDURE AOP_exceptions - not yet implemented.
--MOD PROCEDURE AOP_block - SHOW_ME_LINE = --@@
--MOD procedure stash_comments_and_quotes - retains --@@ for use by AOP_block
Modified   database/LOGGER/Packages/ms_logger.pkb
Modified   database/LOGGER/Packages/ms_logger.pks
--FIX PROCEDURE pop_to_parent_node - more investigation may be required.
--OOPS My call_stack_hist clause does not seem to be reliable. Not sure why need to sort out.
--There were issues with the SUN.Rep_Pb_Pack package.  Popped everything, so no nested nodes.
Implemented Variable Assignment Notes - recognised variables are noted after assignment

Modified   database/LOGGER/Packages/aop_processor.pkb
--NEW  TYPE var_list_typ - holds a list of variables that can be noted.
--NEW REGEX G_REGEX_WHEN_EXCEPT_THEN for commenting on exception handlers with named exceptions.
--ADD PARAM i_var_list IN var_list_typ to a number of routines that harvest and propagate the list of vars in scope.
--MOD FUNCTION AOP_pu_params -
--  Save IN OUT and OUT params in the variable list.
--  Out only params with not need to be included in the param input section.
--NEW FUNCTION AOP_var_defs
--Harvests any vars and appends them to the var list.
--MOD PROCEDURE AOP_block - finds var assignments and checks the var against the scope list.
--MOD function weave - passes the original empty var list into the top level.
Modified   database/LOGGER/UnitTest/aop_test.pkb
--Added var assignment examples.
Now recognises %ROWTYPE variables in the declaration.

Next teach %TYPE and broaden support to include the spec params

Added      database/LOGGER/Functions/supported_data_type.fnc
--Intended to be granted to the indiv user.
Modified   database/LOGGER/Packages/aop_processor.pkb
--MOD g_weave_timeout_secs - add 2 extra seconds so can't evaluate to 0.
--MOD FUNCTION AOP_pu_params - uses supported_data_type
--MOD FUNCTION AOP_var_defs --Looking for ROWTYPE VARS
--stores multiple var names, one for the RECORD and one for each column.
--MOD PROCEDURE AOP_block
--  fix use only G_REGEX_WHEN_EXCEPT_THEN in the main search (also matches for G_REGEX_WHEN_OTHERS_THEN)
--    to avoid failure of REGEX to complete evaulation. (some interaction with G_REGEX_ASSIGN_TO_REC_COL_
--  added support for "l_unit :="  and for "l_unit.unit_name :="
--MOD function weave - go past DECLARE to highlight it.
Modified   database/LOGGER/UnitTest/aop_test.pkb
Modified   database/LOGGER/UnitTest/aop_test.pks
--Addd test cases.
Modified   database/SYS/Users/logger.user
--grant select on DBA_TAB_COLUMNS to logger; - NOT YET USED
Recognises variables with %TYPE definitions.

Modified   database/LOGGER/Packages/aop_processor.pkb
--MOD FUNCTION AOP_var_defs --LOOKING FOR TAB COL TYPE VARS
Modified   database/LOGGER/UnitTest/aop_test.pkb
--Added test case
Creating API to expose logger data for other programs.

Modified   database/LOGGER/Functions/supported_data_type.fnc --Extra datatypes
Modified   database/LOGGER/Packages/ms_logger.pkb
Modified   database/LOGGER/Packages/ms_logger.pks
--NEW FUNCTION f_dba_source
--MOD PROCEDURE warn_user_source_error_lines - uses f_dba_source instead of f_user_source
--NEW FUNCTION process_ref_cursor - returns a ref cursor of formatted lines for output in email by other programs.
Modified   database/LOGGER/Views/aop_source_v.vw
--added COLUMN aop_html.load_datetime  AS html_load_datetime
Modified   database/SYS/Users/logger.user
--grant select on DBA_SOURCE to logger;
Prepare a process report in both plain text and HTML forms
HTML version now resembles the messages browser in f104 on p8

Modified   database/LOGGER/Grants/sun.grt
--grant select on ms_unit_traversal_vw to sun;
--grant select on ms_message_vw to sun;
Modified   database/LOGGER/Packages/ms_logger.pkb
Modified   database/LOGGER/Packages/ms_logger.pks
--NEW FUNCTION get_plain_text_process_report
--NEW FUNCTION get_html_process_report
--DEL FUNCTION process_ref_cursor
Modified   database/LOGGER/UnitTest/ms_test.pkb --test order change.
Modified   database/LOGGER/Views/aop_source_v.vw --add COLUMN using_aop
Modified   database/LOGGER/Views/ms_views.vw
--FIX VIEW ms_message_vw - fixed msg_type for 'Param'
Created a new SmartLoggerAPI

Modified   apex/f104/application/pages/page_00002.sql
--Display HTML_LOAD_DATETIME and USING_AOP
Modified   apex/f104/application/pages/page_00008.sql
--Stop clear cache RP (pagination) when clicking on links within the page.
--Only the process link now resets the RIR (interactive report to primary)
Modified   apex/f104/application/pages/page_00009.sql -- region name changed - defaulted new report columns
Modified   apex/f104/application/pages/page_00010.sql -- region name changed - defaulted new report columns
Modified   apex/f104/application/pages/page_00021.sql -- Char restrictions on field module_name
--new process SubmitNextShowProcessing
Modified   apex/f104/install.sql - new page page_00024.sql
Modified   database/LOGGER/Grants/sun.grt
--grant execute on ms_api to sun;
--removed view grants to sun;
Modified   database/LOGGER/Packages/ms_logger.pkb
Modified   database/LOGGER/Packages/ms_logger.pks
-- EXPOSED FOR THE MS_API
FUNCTION f_process_id
FUNCTION f_process_is_closed
FUNCTION f_process_is_open
-- MOVED to ms_api.pkb
--FUNCTION get_plain_text_process_report
--FUNCTION get_html_process_report
Add        apex/f104/application/pages/page_00024.sql --Public User Feedback page.
Add        database/LOGGER/Packages/ms_api.pkb
Add        database/LOGGER/Packages/ms_api.pks
--ALL NEW
--FUNCTION get_plain_text_process_report RETURN CLOB;
--FUNCTION get_html_process_report RETURN CLOB;
--FUNCTION get_user_feedback_URL RETURN VARCHAR2;
--FUNCTION get_user_feedback_anchor RETURN VARCHAR2;
--FUNCTION get_support_feedback_anchor RETURN VARCHAR2;
New synonym
NEW Patch: LOG-01_06A_06B_SYS - New grants for LOGGER
NEW Patch: LOG-01_06A_06B_LOGGER - Composite patch as below

+ New synonym
+ Created a new SmartLoggerAPI
+ Prepare a process report in both plain text and HTML forms
+ Creating API to expose logger data for other programs.
+ Recognises variables with %TYPE definitions.
+ Now recognises %ROWTYPE variables in the declaration.
+ Implemented Variable Assignment Notes - recognised variables are noted after assignment
+ New feature SHOW_ME_LINE - code lines with trailing --@@ are exposed in a comment.
+ Adding warning for a WHEN OTHERS THEN
+ Creates Note after assignment to a bind variable.
+ Add a PACKAGE_NAME to the Quick AOP screen and use that as the module_name in AOP code.
+ Fixed failure to recognise "-- comment" and ")"
+ New ability to add annotations.
+ Mild refactor of get_next
Commit stashed change

Modified   database/LOGGER/Packages/aop_processor.pkb
--RENAME PROCEDURE splice_here TO wedge