Beispiel #1
0
 /**
  * Returns a new or cached instance of a PBXBuildFile for a file that is not part of a variant
  * group.
  */
 public PBXBuildFile getStandalone(FileReference file) {
   for (PBXBuildFile cached : Mapping.of(standaloneBuildFiles, file).asSet()) {
     return cached;
   }
   PBXBuildFile buildFile = new PBXBuildFile(pbxReferences.get(file));
   mainGroupReferences.add(pbxReferences.get(file));
   standaloneBuildFiles.put(file, buildFile);
   return buildFile;
 }
Beispiel #2
0
 private PBXBuildFile aggregateBuildFile(ImmutableSet<Path> paths, PBXReference reference) {
   Preconditions.checkArgument(!paths.isEmpty(), "paths must be non-empty");
   for (PBXBuildFile cached : Mapping.of(aggregateBuildFiles, paths).asSet()) {
     return cached;
   }
   PBXBuildFile buildFile = new PBXBuildFile(reference);
   mainGroupReferences.add(reference);
   aggregateBuildFiles.put(paths, buildFile);
   return buildFile;
 }