NewModuleData returns a new ModuleData. getBucket and getDepModuleKeys are meant to be lazily-loaded functions where possible. It is OK for getBucket to return a bucket that has extra files that are not part of the Module, this bucket will be filtered as part of this function.
( ctx context.Context, moduleKey ModuleKey, getBucket func() (storage.ReadBucket, error), getDepModuleKeys func() ([]ModuleKey, error), getV1BufYAMLObjectData func() (ObjectData, error), getV1BufLockObjectData func() (ObjectData, error), )
| 73 | // It is OK for getBucket to return a bucket that has extra files that are not part of the Module, this |
| 74 | // bucket will be filtered as part of this function. |
| 75 | func NewModuleData( |
| 76 | ctx context.Context, |
| 77 | moduleKey ModuleKey, |
| 78 | getBucket func() (storage.ReadBucket, error), |
| 79 | getDepModuleKeys func() ([]ModuleKey, error), |
| 80 | getV1BufYAMLObjectData func() (ObjectData, error), |
| 81 | getV1BufLockObjectData func() (ObjectData, error), |
| 82 | ) ModuleData { |
| 83 | return newModuleData( |
| 84 | ctx, |
| 85 | moduleKey, |
| 86 | getBucket, |
| 87 | getDepModuleKeys, |
| 88 | getV1BufYAMLObjectData, |
| 89 | getV1BufLockObjectData, |
| 90 | ) |
| 91 | } |
| 92 | |
| 93 | // *** PRIVATE *** |
| 94 |
no test coverage detected
searching dependent graphs…