Beispiel #1
0
        AsString(
            this FileReference.ESourceTree sourceTree)
        {
            switch (sourceTree)
            {
            case FileReference.ESourceTree.NA:
                return("\"<unknown>\"");

            case FileReference.ESourceTree.Absolute:
                return("\"<absolute>\"");

            case FileReference.ESourceTree.Group:
                return("\"<group>\"");

            case FileReference.ESourceTree.SourceRoot:
                return("SOURCE_ROOT");

            case FileReference.ESourceTree.DeveloperDir:
                return("DEVELOPER_DIR");

            case FileReference.ESourceTree.BuiltProductsDir:
                return("BUILT_PRODUCTS_DIR");

            case FileReference.ESourceTree.SDKRoot:
                return("SDKROOT");

            default:
                throw new Bam.Core.Exception("Unknown source tree, {0}", sourceTree);
            }
        }
Beispiel #2
0
 EnsureFileReferenceExists(
     Bam.Core.TokenizedString path,
     FileReference.EFileType type,
     bool explicitType = true,
     FileReference.ESourceTree sourceTree = FileReference.ESourceTree.NA)
 {
     return(this.EnsureFileReferenceExists(path, null, type, explicitType, sourceTree));
 }
Beispiel #3
0
        public ReferenceProxy(
            Project project,
            FileReference.EFileType fileType,
            Bam.Core.TokenizedString path,
            Object remoteRef,
            FileReference.ESourceTree sourceTree)
            :
            base(project, null, "PBXReferenceProxy", project.GUID, fileType.ToString(), path.Parse(), remoteRef.GUID, sourceTree.ToString())
        {
            this.FileType   = fileType;
            this.Path       = path;
            this.RemoteRef  = remoteRef;
            this.SourceTree = sourceTree;

            project.ReferenceProxies.AddUnique(this);
        }
Beispiel #4
0
        public ReferenceProxy(
            Project project,
            FileReference.EFileType fileType,
            Bam.Core.TokenizedString path,
            Object remoteRef,
            FileReference.ESourceTree sourceTree)
        {
            this.IsA        = "PBXReferenceProxy";
            this.Name       = "PBXReferenceProxy";
            this.FileType   = fileType;
            this.Path       = path;
            this.RemoteRef  = remoteRef;
            this.SourceTree = sourceTree;

            project.ReferenceProxies.AddUnique(this);
        }
Beispiel #5
0
 EnsureFileReferenceExists(
     Bam.Core.TokenizedString path,
     FileReference.EFileType type,
     bool explicitType = true,
     FileReference.ESourceTree sourceTree = FileReference.ESourceTree.NA)
 {
     lock (this.FileReferences)
     {
         var existingFileRef = this.FileReferences.FirstOrDefault(item => item.Path.Equals(path));
         if (null != existingFileRef)
         {
             return(existingFileRef);
         }
         var newFileRef = new FileReference(path, type, this, explicitType, sourceTree);
         this.FileReferences.Add(newFileRef);
         return(newFileRef);
     }
 }