Lines Matching defs:Context
70 type Context struct { struct
71 context.Context argument
74 moduleFactories map[string]ModuleFactory
75 nameInterface NameInterface
76 moduleGroups []*moduleGroup
77 moduleInfo map[Module]*moduleInfo
78 modulesSorted []*moduleInfo
79 preSingletonInfo []*singletonInfo
80 singletonInfo []*singletonInfo
81 mutatorInfo []*mutatorInfo
82 earlyMutatorInfo []*mutatorInfo
83 variantMutatorNames []string
85 depsModified uint32 // positive if a mutator modified the dependencies
87 dependenciesReady bool // set to true on a successful ResolveDependencies
88 buildActionsReady bool // set to true on a successful PrepareBuildActions
91 ignoreUnknownModuleTypes bool
94 allowMissingDependencies bool
97 pkgNames map[*packageContext]string
98 liveGlobals *liveTracker
99 globalVariables map[Variable]ninjaString
100 globalPools map[Pool]*poolDef
101 globalRules map[Rule]*ruleDef
104 ninjaBuildDir ninjaString // The builddir special Ninja variable
105 requiredNinjaMajor int // For the ninja_required_version variable
106 requiredNinjaMinor int // For the ninja_required_version variable
107 requiredNinjaMicro int // For the ninja_required_version variable
109 subninjas []string
112 cachedSortedModuleGroups []*moduleGroup
114 globs map[string]GlobPath
115 globLock sync.Mutex
117 srcDir string
118 fs pathtools.FileSystem
119 moduleListFile string
401 func (c *Context) RegisterModuleType(name string, factory ModuleFactory) {
421 func (c *Context) RegisterSingletonType(name string, factory SingletonFactory) {
443 func (c *Context) RegisterPreSingletonType(name string, factory SingletonFactory) {
457 func (c *Context) SetNameInterface(i NameInterface) {
461 func (c *Context) SetSrcDir(path string) {
466 func (c *Context) SrcDir() string {
496 func (c *Context) RegisterTopDownMutator(name string, mutator TopDownMutator) MutatorHandle {
523 func (c *Context) RegisterBottomUpMutator(name string, mutator BottomUpMutator) MutatorHandle {
568 func (c *Context) RegisterEarlyMutator(name string, mutator EarlyMutator) {
593 func (c *Context) SetIgnoreUnknownModuleTypes(ignoreUnknownModuleTypes bool) {
601 func (c *Context) SetAllowMissingDependencies(allowMissingDependencies bool) {
605 func (c *Context) SetModuleListFile(listFile string) {
609 func (c *Context) ListModulePaths(baseDir string) (paths []string, err error) {
653 func (c *Context) ParseBlueprintsFiles(rootFile string,
664 func (c *Context) ParseFileList(rootDir string, filePaths []string,
794 func (c *Context) WalkBlueprintsFiles(rootDir string, filePaths []string,
925 func (c *Context) MockFileSystem(files map[string][]byte) {
948 func (c *Context) SetFs(fs pathtools.FileSystem) {
953 func (c *Context) openAndParse(filename string, scope *parser.Scope, rootDir string,
1011 func (c *Context) parseOne(rootDir, filename string, reader io.Reader,
1075 func (c *Context) findBuildBlueprints(dir string, build []string,
1117 func (c *Context) findSubdirBlueprints(dir string, subdirs []string, subdirsPos scanner.Position,
1210 func (c *Context) cloneLogicModule(origModule *moduleInfo) (Module, []interface{}) {
1227 func (c *Context) createVariations(origModule *moduleInfo, mutatorName string,
1292 func (c *Context) convertDepsToVariation(module *moduleInfo,
1328 func (c *Context) prettyPrintVariant(variant variationMap) string {
1339 func (c *Context) prettyPrintGroupVariants(group *moduleGroup) string {
1413 func (c *Context) addModule(module *moduleInfo) []error {
1451 func (c *Context) ResolveDependencies(config interface{}) (deps []string, errs []error) {
1455 …ntext) resolveDependencies(ctx context.Context, config interface{}) (deps []string, errs []error) {
1513 …Context) findMatchingVariant(module *moduleInfo, possible *moduleGroup, reverse bool) *moduleInfo {
1541 func (c *Context) addDependency(module *moduleInfo, tag DependencyTag, depName string) []error {
1578 …nc (c *Context) findReverseDependency(module *moduleInfo, destName string) (*moduleInfo, []error) {
1613 …bleDeps *moduleGroup, variations []Variation, far bool, reverse bool) (*moduleInfo, variationMap) {
1663 func (c *Context) addVariationDependency(module *moduleInfo, variations []Variation,
1710 func (c *Context) addInterVariantDependency(origModule *moduleInfo, tag DependencyTag,
1849 func (c *Context) parallelVisit(order visitOrderer, visit func(group *moduleInfo) bool) {
1912 func (c *Context) updateDependencies() (errs []error) {
2038 func (c *Context) PrepareBuildActions(config interface{}) (deps []string, errs []error) {
2096 …c (c *Context) runMutators(ctx context.Context, config interface{}) (deps []string, errs []error) {
2175 func (c *Context) runMutator(config interface{}, mutator *mutatorInfo,
2382 func (c *Context) cloneModules() {
2434 func (c *Context) generateModuleBuildActions(config interface{},
2527 func (c *Context) generateSingletonBuildActions(config interface{},
2583 func (c *Context) processLocalBuildActions(out, in *localBuildActions,
2624 func (c *Context) walkDeps(topModule *moduleInfo, allowDuplicates bool,
2670 func (c *Context) moduleMatchingVariant(module *moduleInfo, name string) *moduleInfo {
2692 func (c *Context) handleRenames(renames []rename) []error {
2706 func (c *Context) handleReplacements(replacements []replace) []error {
2730 func (c *Context) discoveredMissingDependencies(module *moduleInfo, depName string) (errs []error) {
2738 func (c *Context) missingDependencyError(module *moduleInfo, depName string) (errs error) {
2747 func (c *Context) moduleGroupFromName(name string, namespace Namespace) *moduleGroup {
2755 func (c *Context) sortedModuleGroups() []*moduleGroup {
2771 func (c *Context) visitAllModules(visit func(Module)) {
2788 func (c *Context) visitAllModulesIf(pred func(Module) bool,
2809 func (c *Context) visitAllModuleVariants(module *moduleInfo,
2826 func (c *Context) requireNinjaVersion(major, minor, micro int) {
2839 func (c *Context) setNinjaBuildDir(value ninjaString) {
2845 func (c *Context) makeUniquePackageNames(
2904 func (c *Context) checkForVariableReferenceCycles(
2980 func (c *Context) AllTargets() (map[string]string, error) {
3018 func (c *Context) NinjaBuildDir() (string, error) {
3028 func (c *Context) ModuleTypePropertyStructs() map[string][]interface{} {
3037 func (c *Context) ModuleTypeFactories() map[string]ModuleFactory {
3045 func (c *Context) ModuleName(logicModule Module) string {
3050 func (c *Context) ModuleDir(logicModule Module) string {
3054 func (c *Context) ModuleSubDir(logicModule Module) string {
3059 func (c *Context) ModuleType(logicModule Module) string {
3064 func (c *Context) BlueprintFile(logicModule Module) string {
3069 func (c *Context) ModuleErrorf(logicModule Module, format string,
3079 func (c *Context) VisitAllModules(visit func(Module)) {
3083 func (c *Context) VisitAllModulesIf(pred func(Module) bool,
3089 func (c *Context) VisitDirectDeps(module Module, visit func(Module)) {
3107 func (c *Context) VisitDirectDepsIf(module Module, pred func(Module) bool, visit func(Module)) {
3127 func (c *Context) VisitDepsDepthFirst(module Module, visit func(Module)) {
3145 func (c *Context) VisitDepsDepthFirstIf(module Module, pred func(Module) bool, visit func(Module)) {
3165 func (c *Context) PrimaryModule(module Module) Module {
3169 func (c *Context) FinalModule(module Module) Module {
3174 func (c *Context) VisitAllModuleVariants(module Module,
3181 func (c *Context) Singletons() []Singleton {
3190 func (c *Context) SingletonName(singleton Singleton) string {
3202 func (c *Context) WriteBuildFile(w io.Writer) error {
3290 func (c *Context) writeBuildFileHeader(nw *ninjaWriter) error {
3329 func (c *Context) writeNinjaRequiredVersion(nw *ninjaWriter) error {
3341 func (c *Context) writeSubninjas(nw *ninjaWriter) error {
3351 func (c *Context) writeBuildDir(nw *ninjaWriter) error {
3389 func (c *Context) writeGlobalVariables(nw *ninjaWriter) error {
3440 func (c *Context) writeGlobalPools(nw *ninjaWriter) error {
3466 func (c *Context) writeGlobalRules(nw *ninjaWriter) error {
3541 func (c *Context) writeAllModuleActions(nw *ninjaWriter) error {
3610 func (c *Context) writeAllSingletonActions(nw *ninjaWriter) error {
3664 func (c *Context) writeLocalBuildActions(nw *ninjaWriter,