陈清红
2025-04-14 880f3c0257eeb8c37761d484258fdd102a369a19
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Quintiq file version 2.0
#parent: #root
MethodOverride ExecuteStrategyReactive (stream[POAAlgorithm] poa) as stream[POAAlgorithm]
{
  TextBody:
  [*
    //This reactive code block converts the stream[POAAlgorithm] to a POAAlgorithm so we can run the strategy on it.
    //Then it returns it as a stream[POAAlgorithm] so we can return it to the calling code.
    //The below returns the poa after executing the strategy.
    //When using remote execution this call is on the main server and the `POAAlgorithm` is marked for remote execution
    //the reactive code block below moves the `ExecuteStrategy` call to the remote server. It then returns a new `POAAlgorithm`
    //here to the main server.
    poa := poa->( poa ){
      this.ExecuteStrategy( poa );
      return poa;
    }
    return poa;
  *]
}