コード例 #1
0
 /// <summary>
 /// Constructor. Reads a makefile from disk.
 /// </summary>
 /// <param name="Reader">The archive to read from</param>
 public TargetMakefile(BinaryArchiveReader Reader)
 {
     CreateTimeUtc                = new DateTime(Reader.ReadLong(), DateTimeKind.Utc);
     ToolchainInfo                = Reader.ReadString();
     ExternalMetadata             = Reader.ReadString();
     ReceiptFile                  = Reader.ReadFileReference();
     ProjectIntermediateDirectory = Reader.ReadDirectoryReference();
     TargetType              = (TargetType)Reader.ReadInt();
     bDeployAfterCompile     = Reader.ReadBool();
     bHasProjectScriptPlugin = Reader.ReadBool();
     AdditionalArguments     = Reader.ReadArray(() => Reader.ReadString());
     PreBuildScripts         = Reader.ReadArray(() => Reader.ReadFileReference());
     Actions = Reader.ReadList(() => new Action(Reader));
     EnvironmentVariables    = Reader.ReadList(() => Tuple.Create(Reader.ReadString(), Reader.ReadString()));
     OutputItems             = Reader.ReadList(() => Reader.ReadFileItem());
     ModuleNameToOutputItems = Reader.ReadDictionary(() => Reader.ReadString(), () => Reader.ReadArray(() => Reader.ReadFileItem()), StringComparer.OrdinalIgnoreCase);
     HotReloadModuleNames    = Reader.ReadHashSet(() => Reader.ReadString(), StringComparer.OrdinalIgnoreCase);
     DirectoryToSourceFiles  = Reader.ReadDictionary(() => Reader.ReadDirectoryItem(), () => Reader.ReadArray(() => Reader.ReadFileItem()));
     WorkingSet = Reader.ReadHashSet(() => Reader.ReadFileItem());
     CandidatesForWorkingSet = Reader.ReadHashSet(() => Reader.ReadFileItem());
     UObjectModules          = Reader.ReadList(() => new UHTModuleInfo(Reader));
     UObjectModuleHeaders    = Reader.ReadList(() => new UHTModuleHeaderInfo(Reader));
     PluginFiles             = Reader.ReadHashSet(() => Reader.ReadFileItem());
     AdditionalDependencies  = Reader.ReadHashSet(() => Reader.ReadFileItem());
 }
コード例 #2
0
        /// <summary>
        /// Reads data for this dependency cache from disk
        /// </summary>
        private void Read()
        {
            try
            {
                using (BinaryArchiveReader Reader = new BinaryArchiveReader(Location))
                {
                    int Version = Reader.ReadInt();
                    if (Version != CurrentVersion)
                    {
                        Log.TraceLog("Unable to read dependency cache from {0}; version {1} vs current {2}", Location, Version, CurrentVersion);
                        return;
                    }

                    int Count = Reader.ReadInt();
                    for (int Idx = 0; Idx < Count; Idx++)
                    {
                        FileItem File = Reader.ReadFileItem();
                        DependencyFileToInfo[File] = DependencyInfo.Read(Reader);
                    }
                }
            }
            catch (Exception Ex)
            {
                Log.TraceWarning("Unable to read {0}. See log for additional information.", Location);
                Log.TraceLog("{0}", ExceptionUtils.FormatExceptionDetails(Ex));
            }
        }
コード例 #3
0
ファイル: Action.cs プロジェクト: MORTAL2000/UnrealEngine4.26
 public Action(BinaryArchiveReader Reader)
 {
     ActionType                     = (ActionType)Reader.ReadByte();
     WorkingDirectory               = Reader.ReadDirectoryReference();
     bPrintDebugInfo                = Reader.ReadBool();
     CommandPath                    = Reader.ReadFileReference();
     CommandArguments               = Reader.ReadString();
     CommandDescription             = Reader.ReadString();
     StatusDescription              = Reader.ReadString();
     bCanExecuteRemotely            = Reader.ReadBool();
     bCanExecuteRemotelyWithSNDBS   = Reader.ReadBool();
     bIsGCCCompiler                 = Reader.ReadBool();
     bShouldOutputStatusDescription = Reader.ReadBool();
     bProducesImportLibrary         = Reader.ReadBool();
     PrerequisiteItems              = Reader.ReadList(() => Reader.ReadFileItem());
     ProducedItems                  = Reader.ReadList(() => Reader.ReadFileItem());
     DeleteItems                    = Reader.ReadList(() => Reader.ReadFileItem());
     DependencyListFile             = Reader.ReadFileItem();
 }
コード例 #4
0
        /// <summary>
        /// Attempts to load this action history from disk
        /// </summary>
        void Load()
        {
            try
            {
                using (BinaryArchiveReader Reader = new BinaryArchiveReader(Location))
                {
                    int Version = Reader.ReadInt();
                    if (Version != CurrentVersion)
                    {
                        Log.TraceLog("Unable to read action history from {0}; version {1} vs current {2}", Location, Version, CurrentVersion);
                        return;
                    }

                    OutputItemToCommandLineHash = Reader.ReadDictionary(() => Reader.ReadFileItem(), () => Reader.ReadFixedSizeByteArray(HashLength));
                }
            }
            catch (Exception Ex)
            {
                Log.TraceWarning("Unable to read {0}. See log for additional information.", Location);
                Log.TraceLog("{0}", ExceptionUtils.FormatExceptionDetails(Ex));
            }
        }