Пример #1
0
 /// <summary>
 /// Makes the associated accelerator the current one for this thread and
 /// returns a <see cref="ScopedAcceleratorBinding"/> object that allows
 /// to easily recover the old binding.
 /// </summary>
 /// <returns>A scoped binding object.</returns>
 public ScopedAcceleratorBinding BindScoped() => Accelerator.BindScoped();
Пример #2
0
 /// <summary>
 /// Constructs a new accelerator stream.
 /// </summary>
 /// <param name="accelerator">The associated accelerator.</param>
 protected AcceleratorStream(Accelerator accelerator)
     : base(accelerator)
 {
     synchronizeAction = () => Synchronize();
 }
Пример #3
0
 /// <summary>
 /// Constructs an accelerator object.
 /// </summary>
 /// <param name="accelerator">The associated accelerator.</param>
 protected AcceleratorObject(Accelerator accelerator)
 {
     Accelerator = accelerator;
     accelerator.RegisterChildObject(this);
 }
Пример #4
0
 /// <summary>
 /// Adds a profiling marker to the accelerator default stream.
 /// </summary>
 public static void AddProfilingMarker(this Accelerator accelerator) =>
 accelerator.DefaultStream.AddProfilingMarker();
Пример #5
0
 /// <summary>
 /// Constructs an accelerator object.
 /// </summary>
 /// <param name="accelerator">The associated accelerator.</param>
 protected AcceleratorObject(Accelerator accelerator)
 {
     Accelerator = accelerator ?? throw new ArgumentNullException(nameof(accelerator));
     accelerator.RegisterChildObject(this);
 }