internal BuildContext(BuildPipeline pipeline, BuildConfiguration config, BuildProgress progress = null, Action <BuildContext> mutator = null) :
     base(pipeline, config)
 {
     BuildPipelineStatus = BuildPipelineResult.Success(pipeline, config);
     BuildProgress       = progress;
     mutator?.Invoke(this);
 }
示例#2
0
        internal BuildContext(BuildPipeline pipeline, BuildConfiguration config, BuildProgress progress = null, Action <BuildContext> mutator = null)
        {
            BuildPipeline       = pipeline ?? throw new NullReferenceException(nameof(pipeline));
            BuildConfiguration  = config ?? BuildConfiguration.CreateInstance();
            BuildProgress       = progress;
            BuildPipelineStatus = BuildPipelineResult.Success(pipeline, BuildConfiguration);

            mutator?.Invoke(this);

            // Work-around for assets that can be garbage collected during a build
            BuildConfiguration.GCPin();
            BuildPipeline.GCPin();
        }
示例#3
0
 /// <summary>
 /// Construct <see cref="BuildPipelineResult"/> from this <see cref="BuildPipeline"/> that represent a successful execution.
 /// </summary>
 /// <returns>A new <see cref="BuildPipelineResult"/> instance.</returns>
 public BuildPipelineResult Success() => BuildPipelineResult.Success();
 /// <summary>
 /// Get a build result representing a success.
 /// </summary>
 /// <returns>A new build result instance.</returns>
 public BuildPipelineResult Success() => BuildPipelineResult.Success(BuildPipeline, BuildConfiguration);