Exemplo n.º 1
0
		/// <summary>
		/// Run before <see cref="StartRendering(System.Action{System.Exception})"/>
		/// </summary>
		/// <remarks>
		/// Either that or <see cref="RenderGraphCollection.Init"/> must be run. The latter does
		/// this in a global manner (i.e. doesn't just run this method on each RenderGraph).
		/// </remarks>
		/// <returns>This instance</returns>
		public IRenderer Init()
		{
			// set up the dimension change producer
			Source.Dimensions = new BehaviorSubject<Dimensions>(new Dimensions { Width = 128, Height = 32 });
			Destinations.ForEach(dest => {
				var destResizable = dest as IResizableDestination;
				if (destResizable != null) {
					Source.Dimensions.Subscribe(dim => destResizable.SetDimensions(dim.Width, dim.Height));
				}
			});

			// initialize converter
			var converter = Converter as ISource;
			if (converter != null) {
				converter.Dimensions = Source.Dimensions;
			}
			Converter?.Init();

			return this;
		}
Exemplo n.º 2
0
 protected override void CloseReportBase()
 {
     Destinations.ForEach(d => d.WriteItems(_dt));
 }
Exemplo n.º 3
0
 public override void AddDestinations(IsIdentifiableAbstractOptions opts)
 {
     base.AddDestinations(opts);
     Destinations.ForEach(d => d.WriteHeader((from dc in _dtAllFailures.Columns.Cast <DataColumn>() select dc.ColumnName).ToArray()));
 }
Exemplo n.º 4
0
 public override void AddDestinations(IsIdentifiableAbstractOptions opts)
 {
     base.AddDestinations(opts);
     Destinations.ForEach(d => d.WriteHeader(_headerRow));
 }
Exemplo n.º 5
0
		/// <summary>
		/// Clears the display on all destinations.
		/// </summary>
		public void ClearDisplay()
		{
			Destinations.ForEach(dest => dest.ClearDisplay());
		}