This commit is contained in:
Michael Schimmel
2025-06-06 01:22:25 +02:00
parent 73d656cda5
commit c4d8607d17
13 changed files with 393 additions and 173 deletions
+4 -4
View File
@@ -14,13 +14,13 @@ uses
type
// Helper class to notify a latch when its Notify method is called.
TLatchNotifierSubscriber = class(TInterfacedObject, IMycSubscriber)
TLatchNotifierSubscriber = class(TInterfacedObject, TSignal.ISubscriber)
private
FGateLatch: TLatch.ILatch;
public
constructor Create(AGateLatch: TLatch.ILatch);
// IMycSubscriber
function Notify: Boolean; // Implements IMycSubscriber.Notify [cite: 46, 181, 299]
// TSignal.ISubscriber
function Notify: Boolean; // Implements TSignal.ISubscriber.Notify [cite: 46, 181, 299]
end;
[TestFixture]
@@ -251,7 +251,7 @@ var
LPrerequisiteFuture1, LPrerequisiteFuture2: TFuture<Integer>.IFuture;
LMainFuture: TFuture<string>.IFuture;
LGateLatch: TLatch.ILatch;
LSub1, LSub2: IMycSubscriber; // To hold the TLatchNotifierSubscriber instances
LSub1, LSub2: TSignal.ISubscriber; // To hold the TLatchNotifierSubscriber instances
LInitStateP1, LInitStateP2: TLatch.ILatch;
Subscriptions: array[1..2] of TSignal.TSubscription; // To manage subscriptions
const