/// <inheritdoc/> protected override void Dispose(bool disposing) { if (disposing) { RawResults = null; m_Errors = null; } }
/// <summary> /// Sets the result of the graph processing. /// </summary> /// <param name="results">The results.</param> /// <param name="errorModels">The error to display.</param> public void SetResults(GraphProcessingResult results, IEnumerable <IGraphProcessingErrorModel> errorModels) { m_State.RawResults = results; m_State.m_Errors?.Clear(); if (errorModels != null) { m_State.m_Errors?.AddRange(errorModels); } m_State.SetUpdateType(UpdateType.Complete); }
/// <summary> /// Converts the errors generated by the processing of the graph to instances of <see cref="IGraphProcessingErrorModel"/>. /// </summary> /// <param name="stencil">The stencil.</param> /// <param name="results">The graph processing results used as the source of errors to convert.</param> /// <returns>The converted errors.</returns> public static IEnumerable <IGraphProcessingErrorModel> GetErrors(Stencil stencil, GraphProcessingResult results) { if (results?.Errors != null) { return(results.Errors.Select(stencil.CreateProcessingErrorModel).Where(m => m != null)); } return(Enumerable.Empty <IGraphProcessingErrorModel>()); }
public virtual void OnGraphProcessingFailed(IGraphModel graphModel, GraphProcessingResult results) { }