summaryrefslogtreecommitdiff
path: root/android/hooks.go
diff options
context:
space:
mode:
Diffstat (limited to 'android/hooks.go')
-rw-r--r--android/hooks.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/android/hooks.go b/android/hooks.go
index 47f69d1e8..f43a007a0 100644
--- a/android/hooks.go
+++ b/android/hooks.go
@@ -39,6 +39,12 @@ type LoadHookContext interface {
moduleFactories() map[string]blueprint.ModuleFactory
}
+// Add a hook that will be called once the module has been loaded, i.e. its
+// properties have been initialized from the Android.bp file.
+//
+// Consider using SetDefaultableHook to register a hook for any module that implements
+// DefaultableModule as the hook is called after any defaults have been applied to the
+// module which could reduce duplication and make it easier to use.
func AddLoadHook(m blueprint.Module, hook func(LoadHookContext)) {
blueprint.AddLoadHook(m, func(ctx blueprint.LoadHookContext) {
actx := &loadHookContext{