watch_feature_manager Module

Feature plugin manager.

Provides storage and fan-out calls to a set of enabled feature plugins.

The manager owns a growable array of feature objects. Calls are forwarded to each feature in insertion order.


Uses

  • module~~watch_feature_manager~~UsesGraph module~watch_feature_manager watch_feature_manager fpm_strings fpm_strings module~watch_feature_manager->fpm_strings iso_fortran_env iso_fortran_env module~watch_feature_manager->iso_fortran_env module~watch_feature_api watch_feature_api module~watch_feature_manager->module~watch_feature_api module~watch_types watch_types module~watch_feature_manager->module~watch_types module~watch_feature_api->fpm_strings module~watch_feature_api->iso_fortran_env module~watch_feature_api->module~watch_types module~watch_types->fpm_strings module~watch_types->iso_fortran_env fpm_command_line fpm_command_line module~watch_types->fpm_command_line

Used by

  • module~~watch_feature_manager~~UsedByGraph module~watch_feature_manager watch_feature_manager module~watch_engine watch_engine module~watch_engine->module~watch_feature_manager module~watch_feature_factory watch_feature_factory module~watch_engine->module~watch_feature_factory module~watch_feature_factory->module~watch_feature_manager

Derived Types

type, public ::  feature_manager_t

Container for multiple feature instances and their callback fan-out.

Components

Type Visibility Attributes Name Initial
type(feature_box_t), public, allocatable :: feat(:)

Type-Bound Procedures

procedure, public :: add => fm_add
procedure, public :: init_all
procedure, public :: on_after_run_all
procedure, public :: on_before_run_all
procedure, public :: on_change_detected_all
procedure, public :: on_manifest_changed_all
procedure, public :: on_start_all
procedure, public :: on_watch_list_built_all

type, private ::  feature_box_t

A thin wrapper to store an allocatable polymorphic feature instance.

Components

Type Visibility Attributes Name Initial
class(watch_feature_t), public, allocatable :: p

Subroutines

private subroutine fm_add(self, f)

Add a feature instance to the manager, transferring ownership.

Read more…

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
class(watch_feature_t), intent(inout), allocatable :: f

private subroutine init_all(self, cfg)

Call init(cfg) on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
type(watch_config_t), intent(in) :: cfg

private subroutine on_after_run_all(self, exitstat, seconds)

Call on_after_run(exitstat, seconds) on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
integer, intent(in) :: exitstat
real, intent(in) :: seconds

private subroutine on_before_run_all(self, cmd)

Call on_before_run(cmd) on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
character(len=:), intent(inout), allocatable :: cmd

private subroutine on_change_detected_all(self, changed)

Call on_change_detected(changed) on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
type(string_t), intent(in), allocatable :: changed(:)

private subroutine on_manifest_changed_all(self, old_key, new_key)

Call on_manifest_changed(old_key, new_key) on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
integer(kind=int64), intent(in) :: old_key
integer(kind=int64), intent(in) :: new_key

private subroutine on_start_all(self)

Call on_start() on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self

private subroutine on_watch_list_built_all(self, files, roots)

Call on_watch_list_built(files, roots) on all registered features.

Arguments

Type IntentOptional Attributes Name
class(feature_manager_t), intent(inout) :: self
type(string_t), intent(inout), allocatable :: files(:)
type(root_info_t), intent(inout), allocatable :: roots(:)