Batch.DefaultBatchSynchronization
- Aktualisiert2025-07-21
- 2 Minute(n) Lesezeit
Batch.DefaultBatchSynchronization
Syntax
Batch.DefaultBatchSynchronization
Data Type
Use the following constants with this data type:
- BatchSyncType_None –(Value: 0) Do not use Batch synchronization.
- BatchSyncType_OneThreadOnly –(Value: 3) Use a One Thread Only section to specify that only one thread in the batch executes the code in the section. Typically, you use this type of section to perform an operation that applies to the batch as a whole, such as raising the temperature in a test chamber. When all threads in a batch arrive at their respective instances of the Batch.EnterSynchronizedSection method, TestStand releases only the thread with the lowest order number. When that thread arrives at the Batch.ExitSynchronizedSection method for the section, all remaining threads in the batch jump to the Batch.ExitSynchronizedSection method. The threads in the batch then exit the section together.
- BatchSyncType_Parallel –(Value: 2) Use a Parallel section to specify that when all threads in the batch arrive at their respective instances of the Batch.EnterSynchronizedSection method, TestStand releases all threads at once. Each thread blocks after reaching the Batch.ExitSynchronizedSection method for the section until all threads can exit the section together.
- BatchSyncType_Serial –(Value: 1) Use a Serial section to ensure that each thread in a batch executes the section sequentially and in the order you specify when you create the batch. When all threads in a batch arrive at their respective instances of the Batch.EnterSynchronizedSection method, TestStand releases one thread at a time in ascending order according to the order numbers you assigned to the threads when you added them to the batch. As each thread executes the Batch.ExitSynchronizedSection method, the next thread in the batch proceeds from the Batch.EnterSynchronizedSection method. After all threads in the batch arrive at the Batch.ExitSynchronizedSection method, the threads all unblock together.
Purpose
Specifies the default type of batch synchronization. This setting affects the per-step batch synchronization setting when you set the Batch Synchronization option on the Synchronization tab of the Step Properties dialog box to Use Model Setting . Per-step batch synchronization treats each step as if it were within its own Synchronized section of the type you specify.